473,406 Members | 2,208 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Session resetting

This seems to be related to the ViewState error that is now starting to
plague ASP.Net apps. When the Application Pool is recycled, the Session
seems to be getting reset. When this is done, session information is
lost and my app forgets what rules a user has. I'd rather not recode to
read this from the database for every page, but I wonder if I have no
other choice. Anyone else notice the Session resetting?
Nov 19 '05 #1
3 1745
The ASP.NET worker process recycles for various reasons and it happens more
often that people would expect. You have to design/code for it, including
the possibility of InProc session being lost. To save session, keep it out
of the worker process via the State Server or the Sql DB, or just don't use
Session state which is somtimes possible, depending upon what you're doing.

-Brock
DevelopMentor
http://staff.develop.com/ballen
This seems to be related to the ViewState error that is now starting
to plague ASP.Net apps. When the Application Pool is recycled, the
Session seems to be getting reset. When this is done, session
information is lost and my app forgets what rules a user has. I'd
rather not recode to read this from the database for every page, but I
wonder if I have no other choice. Anyone else notice the Session
resetting?


Nov 19 '05 #2
How do I use State Server or SQL DB?

Once a user is logged in, is there any other way of knowing who they
are? I have a roles (not rules...typo) based system where each role is
assigned various privileges. Certain pages require certain privileges
and so do certain controls.

Thanks.

Brock Allen wrote:
The ASP.NET worker process recycles for various reasons and it happens
more often that people would expect. You have to design/code for it,
including the possibility of InProc session being lost. To save session,
keep it out of the worker process via the State Server or the Sql DB, or
just don't use Session state which is somtimes possible, depending upon
what you're doing.

-Brock
DevelopMentor
http://staff.develop.com/ballen
This seems to be related to the ViewState error that is now starting
to plague ASP.Net apps. When the Application Pool is recycled, the
Session seems to be getting reset. When this is done, session
information is lost and my app forgets what rules a user has. I'd
rather not recode to read this from the database for every page, but I
wonder if I have no other choice. Anyone else notice the Session
resetting?


Nov 19 '05 #3
This is just a setting in the web.config. If you want to use State Server be
sure that the service is running (ASP.NET State Service), if SQL Server is
your choice run InstallSQLState.sql in
windows\Microsoft.NET\Framework\VERSION\ once.

HTHs

Daniel
"No One" <ai*******@blahblahblah.com> schrieb im Newsbeitrag
news:kh************@gandalf.grey-net.com...
How do I use State Server or SQL DB?

Once a user is logged in, is there any other way of knowing who they are?
I have a roles (not rules...typo) based system where each role is assigned
various privileges. Certain pages require certain privileges and so do
certain controls.

Thanks.

Brock Allen wrote:
The ASP.NET worker process recycles for various reasons and it happens
more often that people would expect. You have to design/code for it,
including the possibility of InProc session being lost. To save session,
keep it out of the worker process via the State Server or the Sql DB, or
just don't use Session state which is somtimes possible, depending upon
what you're doing.

-Brock
DevelopMentor
http://staff.develop.com/ballen
This seems to be related to the ViewState error that is now starting
to plague ASP.Net apps. When the Application Pool is recycled, the
Session seems to be getting reset. When this is done, session
information is lost and my app forgets what rules a user has. I'd
rather not recode to read this from the database for every page, but I
wonder if I have no other choice. Anyone else notice the Session
resetting?



Nov 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

8
by: riprod | last post by:
Someone in the IIS newsgroup suggest I post this here, so sorry in advance for the cross posting. I have a Win 2003 SP1 with IIS 6 and host about 40 websites, most of them useing ASP/VB with...
14
by: Bobby | last post by:
I have this line, at this time the value of Session("Login") is 1: Response.Write "<a href=" & Request("script_name") & _ "?action=show&o=" & rsCustOrders("OrderID") & _ ">" &...
5
by: Jon Booth | last post by:
I want to write an apsx page that when loaded does not refresh Session.Timeout. It is going to be running in an iframe and refreshing every couple of minutes. example. User has 15 minutes left...
2
by: Dinkster | last post by:
BackGround: - We are new to ASP - We thought we would experiment with using the session object (in proc) to store a small amount of data. - We get different results when cookieless is set to...
1
by: Mike | last post by:
Hey guys need some help on session state. I'm trying to create an ASP.NET page to add items to it. W.G. if your out there I could still use some help! I'm not quite sure how to get it to work....
3
by: usenet | last post by:
Hi all, I've created a custom session handler that saves session data to a MySQL database. If the database server is down, I'd like to fallback to PHP's default session handler (files) until the...
6
by: awebguynow | last post by:
I'm writing a pretty complex webapp, that ideally will have 2-3 popup windows, but I am losing my session information when I open a new window. Is there a way to retain or replicate Session...
2
by: Doogie | last post by:
Hi, We have a page we want to refresh every 30 minutes so that users can get up to date info. The problem is that there is information within the session that we need in each refresh to determine...
1
by: =?Utf-8?B?TWlrZSBNY0FsbGlzdGVy?= | last post by:
I have not been able to find anything about this problem, so it must be configuration on our server, somehow... What we are observing is on Windows Server 2003/IIS 6 our AJAX UpdatePanels are...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.