ASP.NET Development Server or Localhost IIS?

前端 未结 11 604
北海茫月
北海茫月 2020-12-05 01:02

Currently our dev team set up all the websites they\'re working on in IIS on their local machine. We\'re thinking of switching to using the built in ASP.NET development serv

相关标签:
11条回答
  • 2020-12-05 01:28

    In VS12 the development server is way slow, takes a few seconds to download a 2kbyte file. This did not happen in vs10. When you have a bunch of jquery files and css this is a real problem. Also every page requeries all the css/js files. Very very slow regression testing.

    0 讨论(0)
  • 2020-12-05 01:31

    The main issue I've run into with the dev server is SerializationExceptions with custom security principals stored on the thread context. Details here.

    0 讨论(0)
  • 2020-12-05 01:32

    I know at one point I had an issue with Authentication not working as expected on Cassini (built in development server)

    Also, if you need to test things like ISAPI plugins (a re-writer for example) I'm not sure how that's done on Cassini.

    The constantly changing port is also rather disconcerting to me. Also, for each web project in your solution it fires up another instance of a Casini server, and each one takes anywhere from 20 to 50 MB of memory.

    I use IIS all the time, it's pretty easy to setup, and you guys are already doing that...

    0 讨论(0)
  • 2020-12-05 01:34

    It's a very good idea. Here are some reasons for:

    • You no longer need admin access to your machine for web development (it can still be helpful).
    • It's much easier to test a quick change and continue work, and faster iteration cycles are good.
    • It can simplify setup and deployment of your development environments.
    • The XP version of IIS has limitation that are not present in the Server version that Cassini side-steps.

    The only argument I know against is that there are a couple very rare edge cases where the Cassini built-in server doesn't exactly mimic IIS because you're using odd port numbers. I doubt you'll ever run into them, and using Cassini as the primary dev environment does not preclude developers from also having access to IIS on the machine. In fact, my preferred setup is Cassini first for most small work, then deploy to my local IIS for more in-depth testing before moving code back to the shared source repository.

    [Edit]
    Forgot about url re-writing. You do need IIS for that. And an example of a limitation of the built-in XP IIS is that you are limited to one site in XP (can have multiple applications, but that's a different thing).

    0 讨论(0)
  • 2020-12-05 01:34

    I had to switch (back) to IIS for one project, because I needed to set some virtual directories which is not possible on the ASP.NET Development Web Server.

    0 讨论(0)
提交回复
热议问题