locked
Self Hosting Web Application versus IIS Hosting? RRS feed

  • Question

  • I am in the process of building a Web based client for a Server application which is running as a Windows Service. The server application currently has a Windows Form based Client Application written in C# and the idea is to obsolete it and provide a new Web based Client Application. The Server application will be exposing REST based APIs and the Client Application would be using the REST APIs to communicate with the Server Application. (Currently the Server App exposes SOAP based endpoints which are consumed by the Windows Form Based App)

    The Browser based client application would be written using Angular JS. The Client Application would be used by at max 10 concurrent users. The App is targeted for system administrators and would be used inside the enterprise environment.

    Another requirement is to integrate Active Directory Authentication for the Client Application. So given the performance requirement and authentication requirements, I am wondering whether I should use IIS for hosting the Web Application. Or should I just use the existing Server to self host the web pages.

    If at all I go with Self Hosting option, would Katana Self host be a good option? Or should i use WCF Rest kit to serve the pages?

    What are the performance implications of using a Self Hosted mechanism for hosing the Web Application compared to IIS?

    Any suggestion would be greatly appreciated.

    Monday, October 26, 2015 12:09 PM

Answers

  • You suggested Web API and ASP.NET MVC. I will be using Web API for exposing the interfaces on the Server. Is there any specific reason you are suggesting ASP .NET. I plan to use Angular JS for building a SPA Client which will be using REST APIs to talk to Server. I wonder why ASP .net was suggested as the technology for Web Application. It would be great if you can throw some light on it.

    It's because ASP.NET WEB API, which is Json and rest based,  and ASP.NET MVC work well together along with JavaScript. Angular JS is just another JavaScript library. And if you are thinking you can only have JavaScript clients without some C# or VB.NET classes being involved in the form of controllers Web API or MVC, then you may be rudely awakened.

    I understand that IIS has all the benifits you mentioned. But I am wondering whether all those benefits are really needed for hosting a Web App that would be used by at max 10 concurrent users. Katana Self host has the ability to wire up middle wares which are capable of performing required functionalities. So one should be able to get required functionalities. 

    IIS, a Web server, will always be the better choice in hosting  web based solutions Internet or Internet.

    So now the question is should I just go by the self hosting way using OWIN Self host or use IIS.Would IIS be part of all versions of Windows OS by default? What is the over head of using

    IIS is on all NT based O/S(s) Win NT 4.0 to Win 8 professional versions of the workstation O/S. IIS on all Windows server based O/S. IIS is on my Win 10 Home version of the O/S.

    I suggest that you start thinking about the below and not put up some hack-bait.

    https://en.wikipedia.org/wiki/Separation_of_concerns

    https://en.wikipedia.org/wiki/Multitier_architecture

    http://www.lhotka.net/weblog/TheCostsAndSecurityBenefitsOfNtierOver2tier.aspx

    • Proposed as answer by Grady_Dong Thursday, November 5, 2015 3:22 AM
    • Marked as answer by Grady_Dong Friday, November 6, 2015 1:16 AM
    Saturday, October 31, 2015 8:01 PM

All replies

  • Hello there,

    Please refer below link which explained very well

    http://forums.asp.net/t/1908235.aspx?Self+hosting+or+IIS+hosted+

    Cheers

    Dinesh

    • Proposed as answer by Dinesh Gabhane Monday, October 26, 2015 1:09 PM
    Monday, October 26, 2015 1:09 PM
  • The Browser based client application would be written using Angular JS. The Client Application would be used by at max 10 concurrent users. The App is targeted for system administrators and would be used inside the enterprise environment.

    Then what you should be using then is Web API and ASP.NET MVC.

    Another requirement is to integrate Active Directory Authentication for the Client Application. So given the performance requirement and authentication requirements, I am wondering whether I should use IIS for hosting the Web Application. Or should I just use the existing Server to self host the web pages.

    I have never heard of self hosting Web pages. Web pages are either served by the Web server (server controls), or they are hosted and served  in the browser on the client side via JavaScript.

    Most would go with a Web service hosted on IIS, because you don't have to worry about and deal with ways of recycling the service. IIS takes care of that kind of stuff.

    https://msdn.microsoft.com/en-us/library/ms730158%28v=vs.110%29.aspx?f=255&MSPPError=-2147217396

    If at all I go with Self Hosting option, would Katana Self host be a good option? Or should i use WCF Rest kit to serve the pages?

    I don't know what you are talking. Either the Web server is serving the pages via server controls, or JavaScript is serving the pages on the client side at the browser. No service of any kind that I know about is serving Web pages.

    Monday, October 26, 2015 2:12 PM
  • Thanks. I had seen this link before, but it talks about hosting web services, and I am specifically looking for hosting a web application. 

    Wednesday, October 28, 2015 12:15 AM
  • Thanks. I had seen this link before, but it talks about hosting web services, and I am specifically looking for hosting a web application. 


    ?????????
    Wednesday, October 28, 2015 1:37 AM
  • Hi DA924

    You suggested Web API and ASP.NET MVC. I will be using Web API for exposing the interfaces on the Server. Is there any specific reason you are suggesting ASP .NET. I plan to use Angular JS for building a SPA Client which will be using REST APIs to talk to Server. I wonder why ASP .net was suggested as the technology for Web Application. It would be great if you can throw some light on it.

    I agree that hosting a Web Application using the Self Hosting is not very common. But I considered that option as the App would be used by at max 10 users concurrently. Microsoft Katana Self Host is meant for providing a simple alternative for IIS hosting (it has other design goals too). 

    http://www.asp.net/aspnet/overview/owin-and-katana/an-overview-of-project-katana

    Here is an example of how to self host web pages using Katana.

    http://www.bfcamara.com/post/52138881551/running-a-desktop-app-with-angularjs-served-from-a

    I understand that IIS has all the benifits you mentioned. But I am wondering whether all those benefits are really needed for hosting a Web App that would be used by at max 10 concurrent users. Katana Self host has the ability to wire up middle wares which are capable of performing required functionalities. So one should be able to get required functionalities. 


    So now the question is should I just go by the self hosting way using OWIN Self host or use IIS.Would IIS be part of all versions of Windows OS by default? What is the over head of using IIS?

    I hope you understood the context and question better now. Any inputs and suggestions would be appreciated. 


    Wednesday, October 28, 2015 6:08 AM
  • Hi DA924

    You suggested Web API and ASP.NET MVC. I will be using Web API for exposing the interfaces on the Server. Is there any specific reason you are suggesting ASP .NET. I plan to use Angular JS for building a SPA Client which will be using REST APIs to talk to Server. I wonder why ASP .net was suggested as the technology for Web Application. It would be great if you can throw some light on it.

    I agree that hosting a Web Application using the Self Hosting is not very common. But I considered that option as the App would be used by at max 10 users concurrently. Microsoft Katana Self Host is meant for providing a simple alternative for IIS hosting (it has other design goals too). 

    http://www.asp.net/aspnet/overview/owin-and-katana/an-overview-of-project-katana

    Here is an example of how to self host web pages using Katana.

    http://www.bfcamara.com/post/52138881551/running-a-desktop-app-with-angularjs-served-from-a

    I understand that IIS has all the benifits you mentioned. But I am wondering whether all those benefits are really needed for hosting a Web App that would be used by at max 10 concurrent users. Katana Self host has the ability to wire up middle wares which are capable of performing required functionalities. So one should be able to get required functionalities. 

    So now the question is should I just go by the self hosting way using OWIN Self host or use IIS.Would IIS be part of all versions of Windows OS by default? What is the over head of using IIS?

    I hope you understood the context and question better now. Any inputs and suggestions would be appreciated. 

    Friday, October 30, 2015 6:38 AM
  • You suggested Web API and ASP.NET MVC. I will be using Web API for exposing the interfaces on the Server. Is there any specific reason you are suggesting ASP .NET. I plan to use Angular JS for building a SPA Client which will be using REST APIs to talk to Server. I wonder why ASP .net was suggested as the technology for Web Application. It would be great if you can throw some light on it.

    It's because ASP.NET WEB API, which is Json and rest based,  and ASP.NET MVC work well together along with JavaScript. Angular JS is just another JavaScript library. And if you are thinking you can only have JavaScript clients without some C# or VB.NET classes being involved in the form of controllers Web API or MVC, then you may be rudely awakened.

    I understand that IIS has all the benifits you mentioned. But I am wondering whether all those benefits are really needed for hosting a Web App that would be used by at max 10 concurrent users. Katana Self host has the ability to wire up middle wares which are capable of performing required functionalities. So one should be able to get required functionalities. 

    IIS, a Web server, will always be the better choice in hosting  web based solutions Internet or Internet.

    So now the question is should I just go by the self hosting way using OWIN Self host or use IIS.Would IIS be part of all versions of Windows OS by default? What is the over head of using

    IIS is on all NT based O/S(s) Win NT 4.0 to Win 8 professional versions of the workstation O/S. IIS on all Windows server based O/S. IIS is on my Win 10 Home version of the O/S.

    I suggest that you start thinking about the below and not put up some hack-bait.

    https://en.wikipedia.org/wiki/Separation_of_concerns

    https://en.wikipedia.org/wiki/Multitier_architecture

    http://www.lhotka.net/weblog/TheCostsAndSecurityBenefitsOfNtierOver2tier.aspx

    • Proposed as answer by Grady_Dong Thursday, November 5, 2015 3:22 AM
    • Marked as answer by Grady_Dong Friday, November 6, 2015 1:16 AM
    Saturday, October 31, 2015 8:01 PM