开发者

Why would you want to deploy a Web Service as a Web Role on Azure?

I was under the impression that a Web Service that should be run under a worker role. I j开发者_运维问答ust found out that a web service can be setup using the web role. What are the advantages to using one role over the other ?


If you use the Web Role, your service will be hosted in a full IIS, and you can for exemple co-host it with your Web site, and use all of IIS features.

If you go for a Worker Role, you will have to new up a ServiceHost to host your service. You will not run within IIS.


I answered a similar question here. Note that, even with a Web Role, you'll have your choice of hosting your web service via IIS or on your own with a Service Host.

Back in March, there was an update to input port handling, so now you can spread your input ports out across your roles in any fashion you like, even having up to 25 in one role. This mitigates issues related to single-role deployments with RDP enabled (since in that case, RDP consumes 2 input ports). See my blog post here for more info about port allocation, as it really opens up options for you when setting up service-hosting.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜