views:

140

answers:

4

I dislike it when I lose the session state of my ASP.NET web app when changing code.

Losing the session state means I have to log in over and over again. It's annoying.

Is there anyway I can reconfigure my app so that I can make changes to code and not have to re-authenticate to view those changes?

(I know that changing .ASPX files does this fine. My concern is over App_Code and Bin compiled code.)

+3  A: 

Unfortunately changes in the web.config or in dll's in the bin folder will cause an application reload and there is nothing you can do about it, AFAIK.

Otávio Décio
+2  A: 

I wonder what will happen if you will store session state in StateServer. Maybe it will work ( I will be surprised if it does).

Igal Serban
This seems very promising. Thank you for the link.
Frank Krueger
+1  A: 

If you are in a developer environment you can try disabling logging into the site, or when the site checks for authentication just return your default authentication. For production, a StateServer will help as Igal pointed out.

One last option, store the login information in Session, but as a backup to that use a login table in your database to be able to restore a user's authentication status from a cookie. Obviously, consider security implications.

DavGarcia
+1  A: 

By changing your StateServer to use your machine (enabling the ASP.NET State Service), you won't lose your login.

Steve Wright