"John Saunders" <john.saunders at trizetto.comwrote in
news:Od**************@TK2MSFTNGP03.phx.gbl:
"Michael Bray" <mbray@makeDIntoDot_ctiusaDcomwrote in message
news:Xn****************************@207.46.248.16. ..
>=?Utf-8?B?UGV0ZXIgQnJvbWJlcmcgW0MjIE1WUF0=?=
<pb*******@yahoo.yabbadabbadoo.comwrote in
news:42**********************************@microso ft.com:
>>If you want to be able to preserve your Application variables across
app restarts, you should restore them in the Application_Start event
handler in Global.asax.
But where would I store them that they would persist across
Application Restarts? I would have thought the Application[...]
variable, but wouldn't those variables go away when the app does
restart??
If these are tokens related to clients, then won't the client
connections and any associated data be destroyed by an app restart?
John
Yes that is the problem that we are experiencing... In other words, the
login token is being stored in a Hashtable that is stored in the
Application[...] variable. The clients are crashing when, it appears, the
Application_OnStart gets called and the hashtable is created anew, and
stored in the Application[...]. That's what the original question was
asking, to verify that this is what was (ie that it could) happen this way.
It seems that my suspicion was correct.
I guess the question is, how can I prevent the application from recycling,
or is there a better place to store user login token information? The
application is the highest-level object in terms of lifecycle that I know
of. The only other option would be to store in external system such as
SQL.
-mdb