Created a Basic Azure Service Fabric , Stateful Service, using reliable service framework using .NET core.
Created a values controller with get operation returning string collection
created endpoint configuration in service manifest with protocol of http
Created DNS service name in the application manifest for the service
Created Azure service fabric Cluster from portal
Configured the nodes with ReverseProxy and Enable DNS
Configured the LB rules 8081,80,19080,19000
Have healthprobe at 19000,19080,8081
Published my azure fabric application from Visual studio, and I can open the fabric explorer, it shows my services are deployed correctly
but not able to access the service from outside of cluster
http://domain.eastus2.cloudapp.azure.com:19080/MyCalculatorApplication/AgeCalculatorService/api/values throws exception as {"Error":{"Code":"E_INVALIDARG","Message":"Invalid argument"}}
When you are trying to use the naming service of service fabric, first you should resolve the endpoint using this url:
http://domain.eastus2.cloudapp.azure.com:19080/Services/MyCalculatorApplication/AgeCalculatorService/$/ResolvePartition?api-version=3.0&PartitionKeyType=1&timeout=60
Then you can use one of the endpoints
I'm not sure that this is the correct endpoint.
Your url should be something like this:
http://domain.eastus2.cloudapp.azure.com:SERVICEPORT/api/values
Related
I am new to WCF, I am trying to create a WCF selfhost service with dynamic URL, which will be used to authentication user from client computer. this service will be installed in all client computers and web application should work if it finds this WCF service in client computer. Please Help.
First, you can implement self-hosted wcf,
https://www.c-sharpcorner.com/UploadFile/137605/self-hosting-in-wcf/
https://learn.microsoft.com/en-us/dotnet/framework/wcf/samples/self-host
and then dynamically switch the wcf web service reference url path through the configuration file.
How to make your Service-Reference proxy URL dynamic?
Dynamically switch WCF Web Service Reference URL path through config file
How Dynamically change URL in a WCF Custom Behavior
I have a WebAPI based master web service which provides a list of Azure Service Bus Relay endpoints for on-premises WCF services based on the client who logged onto the Master Service via a WPF desktop App using ADAL Azure Active Directory logon. This works fine, and the master service returns a Service Bus endpoint for the client who logged in.
The client can then connect to the WCF on-premises service via the returned Service Bus endpoint no problem.
However there are certain methods in the on-premises WCF service which need to impersonate the calling client-user and this is where I am stuck. Does anyone know of a way to be able to impersonate a client who has called a WCF service via the Azure Service Bus relay?? I can't "log the user on" in order to impersonate them because I don't know their domain password, I only have available their logon UPN.
You can potentially solve this problem in the same way I did when writing a paper about flowing an identity through azure service bus queues. You would need to have elevated priveledges for your service account running the on premise service which may introduce a vulnerability depending on how your solution works but if you can mitigate that then this approach would work.
The paper is on the following link:
Flowing a Windows Identity through Azure Service Bus Queues
http://microsoftintegration.guru/publications/whitepapers/
Hope this helps
Mike
Just to clarify I am working for the first time with azure. I created a Restful WCF Service a few months ago with SQL Server connection. I deployed the WCF on IIS with the database on SQL Server Express 2012. The service works with no problems.
[OperationContract]
[WebGet(UriTemplate = "feed/{ID}/{Rating}/{Feed}", ResponseFormat = WebMessageFormat.Json)]
string feed(string ID, string Rating, string Feed);
Now I must move the WCF service to Azure. The problem is I have no idea how to deploy the WCF to azure and if it is even possible to deploy the WCF to azure. The database have been moved to azure.
The principal is relatively easy depending on whether you want a Azure WebSite or Cloud Role - for Cloud...
Ensure you have the Azure SDK installed from the WebPlatform Installer.
Add a WCF Cloud Service Role to your project
Expand the out the project and right click onto the 'Roles' node selecting 'Add' and then existing project from your solution.
Publish the role using your Azure credentials.
These two articles provide an end-to-end tutorial that goes into more depth...
http://www.claudiobernasconi.ch/2013/08/03/deploying-a-wcf-service-on-windows-azure/
http://blogs.msdn.com/b/nishasingh/archive/2012/12/05/creating-and-deploying-a-wcf-service-on-windows-azure-and-consuming-it-in-windows-8-store-app.aspx
With this one more specific to Azure Websites
http://blogs.msdn.com/b/brunoterkaly/archive/2014/03/31/moving-a-wcf-service-and-database-to-the-cloud.aspx
HTH
I have a WCF service using wsHttpBinding and Windows Authentication hosted in an intranet environment.
Currently I am trying to host that service into Azure VM. Service is not able to authenticate as it is outside local domain.
Please let me know the steps or rather the configuration, I would need for achieving Windows Authentication. IIS configuration WCF web.config configuration etc.
There is a wealth of information at http://azure.microsoft.com/en-us/documentation/services/active-directory/
If you want to using your domain login's. There are a few approaches to doing this depending on your requirements and this documentation is very good in guiding you to the right solution.
I have a wcf service that run on a server. I have two clients that connecs to the service. We use username and password to authenticate the client.But I recreated the certificate in the same location as previous using PluralSight Software
But after configuring the client to connect to the service I have got following error.
The identity check failed for the outgoing message. The expected identity is 'identity(http://schemas.xmlsoap.org/ws/2005/05/identity/right/possessproperty: http://schemas.xmlsoap.org/ws/2005/05/identity/claims/thumbprint)' for the target endpoint
I got the above error when I tried to login to the service. I have shared my configuration details here.. any help would be appreciated.
CLIENT APP.CONFIG VIA WCF CONFIGURATION EDITOR
SERVICE WEB.CONFIG VIA WCF CONFIGURATION EDITOR
I found the answer. This happens because if you create a new certificate on server which wcf service host then you need to update the service reference in client application. so it will update the app.config file of the client application with latest identity value.