Last post Sep 15, 2013 10:08 PM by Tear09
Sep 12, 2013 11:09 AM|Aan K Davis|LINK
Recently i have discovered that opening Visual Web Developer 2008 Express and opening a remote website under IIS 7, intermittently causes the application to re-start causing users to lose their sessions (we are using in-proc sessions). No code has been altered,
the trigger is just opening the website in Web Developer.
This has definitely only recently started happening. Does anyone know what could be causing this?
Sep 12, 2013 11:14 AM|MetalAsp.Net|LINK
If you touch the web.config file it'll restart the app.
In visual studio you should be opening your local copy of the project/website. You shouldn't be opening a hosted/production level website directly in visual studio. At least I wouldn't.
Sep 12, 2013 11:24 AM|Aan K Davis|LINK
Thanks for the response. I understand about web.config, app_code changes etc but these files are not being touched. I also accept that it's not best practice to operate against a live deployment but with care this has not caused issue in the past.
If web.config is changed then this generates the 'Configuration changed' message. I am not seeing this.
Sep 13, 2013 05:22 AM|Starain chen - MSFT|LINK
Thanks for your post!
According to your description, I tried it using Visual Studio and it works fine. (Session data haven’t loss)
I suggest that you can create a new project, then try it and check the result.
On the other hand, I suggest that you can use the StateServer or SQLServer mode instead of the
InProc mode. For more information, please refer to
Sep 13, 2013 05:38 AM|Aan K Davis|LINK
Thanks for the response. I will try with a new project and see what happens.
It is really strange as it doesn't happen everytime i start Visual Studio. If i open VS several times in succession a rebuild will occur the first time but not the others. If i then leave it for an hour or two before trying again it will cause a rebuild.
I have started moving websites to SQLServer mode which i agree is far more resilient. Most transfer without issue but our main eCommerce site needs changing as classes aren't marked as serializable.
Sep 13, 2013 01:14 PM|Tear09|LINK
Aan K Davis
Most transfer without issue but our main eCommerce site needs changing as classes aren't marked as serializable.
I don't farmilar with SQL Server mode. Do you mean, the data stored in the session will be serializable if using the SQLServer mode?
On the other hand, maybe the log will be recorded in the Event Viewer. You can check the Event Viewer's log.
Sep 15, 2013 10:08 PM|Tear09|LINK
I tried it, the data will be serialized if using the SQKServer mode. So I suggest that you should mark your class as serializable.
By the way, I suggest that you can use the version control tool to manager your code instead of modify the project that has been deployed in the iis. (SVN is the good tool)