I got a wcf service which I'd like to run on azure, but I got several problems:
First: do I choose a web role or a worker role for running the wcf service?
Second: The client uses a call to log into the service, afterwards the service should remember who is logged in (sessions). The problem is, for firewall reasons I probably should use some http-binding. But these seem not to support sessions??
Or do I need AppFabric for sessions (what is AppFabric anyway?)?
Is there a good complete tutorial how to host wcf service?
Open your existing 'WCF service' project and then right click on the project. Move to 'Convert' option and then click 'Convert to Microsoft Azure Cloud Service Project'. It will create an 'Azure cloud service' project using your existing 'WCF service' in the same solution as below.
WCF services can be hosted in any managed application. This is the most flexible option because it requires the least infrastructure to deploy. You embed the code for the service inside the managed application code and then create and open an instance of the ServiceHost to make the service available.
There are three types of hosting environments for WCF services: IIS, WAS, and self-hosting. The term “self-hosting” refers to any application that provides its own code to initialize the hosting environment. This includes console, Windows Forms, WPF, and managed Windows services.
Azure App Service enables you to build and host web applications in the programming language of your choice without managing infrastructure. Learn how to create a website through the hosted web app platform in Azure App Service.
If you host your WCF service in a Web role, you'll then have all the benefits of IIS (pooling, caching, logging, etc.). You can rely on the WCF Web Role template and simply add a WCF service (which manifests itself as an svc) - and with the new SDK 1.3, you should be able to host a WCF service alongside your website in the same role.
You can also new up a ServiceHost in a worker role. With the worker role, you'll have complete control, but you'll lose the benefits of IIS.
For WCF labs, start with the Azure Platform Training Kit. You'll see labs for:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With