none
WCF and Windows Service RRS feed

  • Question

  • Hi folks,

    Not sure if this is the right thread to ask this, but can you enlighten me on these questions that I cannot found on the net please?

    1. Can a WCF live on its own without IIS?

    2. If an application uses Windows service and net.tcp protocol, will it still need IIS or it can be designed without it?

    3. We have several WCF services that are used by our front-end, and by browsing thru IIS, I can see all these .svc files. however when I shutdown my IIS so  I can run a local copy of the front-end application, the application doesn't seem to need these services and it is still able to continue to run. I found the end-point that is being used by the application is something like "net.tcp://localhost:1234/[NameOfServiceHere]

    4. We also have background tasks that were created on Windows services but could be using any protocol like net.tcp. If so, I'm coming back to the question of - if net.tcp protcol requires IIS?

     

    Sorry for the many questions, I just don't have anyone to ask that knows how these work as the software developer/architect that designed and created all of these applications have resigned without even writing the documentation.

    I 'll try to answer all clarifications that relates to my questions as much as I could.

    Thanks and have a nice day.

    Friday, April 11, 2014 10:07 AM

Answers

  • Hi, WCF can live without IIS, actually, you can host WCF in your applicaiton, please see below link, it will tell you everything:

    http://msdn.microsoft.com/en-us/library/ms730158(v=vs.110).aspx

    Friday, April 11, 2014 2:45 PM
  • HI

    Here are the answers for your 3 questions

    1.Can a WCF live on its own without IIS? 

    Yes, WCF service can be run without an IIS, when you press F5 in Visual Studio IDE, it runs using inbuilt ASPDEV server, which has random port assigned , in your case it is 1234 port

    net.tcp://localhost:1234/[NameOfServiceHere]

    2.If an application uses Windows service and net.tcp protocol, will it still need IIS or it can be designed without it?

    No when the WCF service hosted on windows service, there is no need to of IIS, WCf service can be hosted on different ways, please check in MSDN site for different hosting mechanism for WCF service, using net.tcp binding WCF service can be hosted on both IIS and on windows service 

    3,Refer my answer #1 already answered

    4. net.tcp binding for WCF service is used when your service should be required to be serve the purpose of intranet application/ clients, net.tcp is fater as compare to basichttpBidning and wshttpBining, WCF service with net.Tcp binding can be hosted on IIS server or windows service not both it depends on your deployment decision

    Regards

    Rajesh Sajjanar

    Sunday, April 13, 2014 6:00 PM

All replies

  • Hi, WCF can live without IIS, actually, you can host WCF in your applicaiton, please see below link, it will tell you everything:

    http://msdn.microsoft.com/en-us/library/ms730158(v=vs.110).aspx

    Friday, April 11, 2014 2:45 PM
  • HI

    Here are the answers for your 3 questions

    1.Can a WCF live on its own without IIS? 

    Yes, WCF service can be run without an IIS, when you press F5 in Visual Studio IDE, it runs using inbuilt ASPDEV server, which has random port assigned , in your case it is 1234 port

    net.tcp://localhost:1234/[NameOfServiceHere]

    2.If an application uses Windows service and net.tcp protocol, will it still need IIS or it can be designed without it?

    No when the WCF service hosted on windows service, there is no need to of IIS, WCf service can be hosted on different ways, please check in MSDN site for different hosting mechanism for WCF service, using net.tcp binding WCF service can be hosted on both IIS and on windows service 

    3,Refer my answer #1 already answered

    4. net.tcp binding for WCF service is used when your service should be required to be serve the purpose of intranet application/ clients, net.tcp is fater as compare to basichttpBidning and wshttpBining, WCF service with net.Tcp binding can be hosted on IIS server or windows service not both it depends on your deployment decision

    Regards

    Rajesh Sajjanar

    Sunday, April 13, 2014 6:00 PM