none
Using WebApi in Windows Service which has already WCF service RRS feed

  • Question

  • Hi 

    I have a WCF service which is hosted in Windows Service and we want to implement a new methods with WebApi in the existing WCF services solution. We have used StructureMap for WCF and when i try to implement the WebApi it is not working.

    my question is whether we can use WebApi along with WCF service in the same windows service?

    if possible pls let me know the possible options.

    thanks  in advance

    Wednesday, July 13, 2016 5:15 AM

Answers

  • Hi SKumar,

    >> we want to implement a new methods with WebApi in the existing WCF services solution. We have used StructureMap for WCF and when i try to implement the WebApi it is not working.

    What do you mean with implement WebAPI method in WCF service? As my understanding, WCF and Web api are independent products, how did you use them in the same solution?

    >> my question is whether we can use WebApi along with WCF service in the same windows service?

    Have you achieved host Web api in windows service without wcf service? In my option, if Web api and WCF are independent, you could host them in the same windows service. You could refer the link below for host web api in windows service.

    # Self-Hosting Web API 2 Using OWIN
    http://blog.thedigitalgroup.com/amitd/2016/02/24/self-hosting-webapi-2-using-owin/

    As the reply from DA924x, if you have any issue about hosting Web API in windows service, I would suggest you go to Web api forum for help.

    Best Regards,

    Edward

    Note: This response contains a reference to a third party World Wide Web site. Microsoft is providing this information as a convenience to you. Microsoft does not control these sites and has not tested any software or information found on these sites;Therefore, Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there.There are inherent dangers in the use of any software found on the Internet, and Microsoft cautions you to make sure that you completely understand the risk before retrieving any software from the Internet.


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.



    Friday, July 15, 2016 11:53 AM

All replies

  • You need to ask about Web API at its forum.

    http://forums.asp.net/1246.aspx/1?Web+API

    Wednesday, July 13, 2016 2:15 PM
  • Hi SKumar,

    >> we want to implement a new methods with WebApi in the existing WCF services solution. We have used StructureMap for WCF and when i try to implement the WebApi it is not working.

    What do you mean with implement WebAPI method in WCF service? As my understanding, WCF and Web api are independent products, how did you use them in the same solution?

    >> my question is whether we can use WebApi along with WCF service in the same windows service?

    Have you achieved host Web api in windows service without wcf service? In my option, if Web api and WCF are independent, you could host them in the same windows service. You could refer the link below for host web api in windows service.

    # Self-Hosting Web API 2 Using OWIN
    http://blog.thedigitalgroup.com/amitd/2016/02/24/self-hosting-webapi-2-using-owin/

    As the reply from DA924x, if you have any issue about hosting Web API in windows service, I would suggest you go to Web api forum for help.

    Best Regards,

    Edward

    Note: This response contains a reference to a third party World Wide Web site. Microsoft is providing this information as a convenience to you. Microsoft does not control these sites and has not tested any software or information found on these sites;Therefore, Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there.There are inherent dangers in the use of any software found on the Internet, and Microsoft cautions you to make sure that you completely understand the risk before retrieving any software from the Internet.


    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click HERE to participate the survey.



    Friday, July 15, 2016 11:53 AM