开发者

Which is the best option to host a nettcp WCF service

I have a nettcp service which I have to host. I have three op开发者_如何学编程tions -

  1. IIS 7

  2. Windows Service

  3. A console application

I would be grateful if anybody could give some valuable thoughts on which option is better vis-a-vis other one.


Here are some of my observations:

IIS 7:

Pros:

  • Ready made hosting environment inside IIS
  • Will work with pretty much any hosting environment

Cons:

  • HTTP Only
  • Configuration slightly more complex

WAS:

Pros:

  • Ready made and familiar process model to that of IIS
  • No dependency on IIS
  • All protocols supported

Cons:

  • Not all shared hosting environments will support non-http protocol bindings or unusual port numbers.
  • Configuration slightly more complex

Windows Service:

Pros:

  • Starts when windows starts
  • You can start/stop the service via the service control manager
  • All protocols supported

Cons:

  • Some extra steps to deploy/re-deploy (installutil)
  • You need some extra boilerplate code to support the service implementation
  • Not ideal if you can't have access to the server to install (e.g. shared hosting)

Console Application:

Pros:

  • Fast and simple to deploy for testing purposes
  • All protocols supported

Cons:

  • You need to be logged on to start the process
  • Loss of session or machine shutdown will kill the service
  • Console/RDP access required
0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜