Session State - Should I use it?

Hi,

I pretty new to web development so I'm still easily confused. Right now I'm confused about Session State. One book will say use it at will, while another will say that it should be avoided whenever possible. I'm developing a web app that will typically have between 500-1000 concurrent users and which could really do with using several Session State values. Can anyone offer any advice or opinions on this? How does SessionState performance compare to ViewState??
Cheers
robby
0
FlashHeart
3/24/2004 9:38:29 AM
asp.net.getting-started 91979 articles. 4 followers. Follow

1 Replies
905 Views

Similar Articles

[PageSpeed] 13
Get it on Google Play
Get it on Apple App Store

Well scalability and session state are at odds with each other. I personally try to avoid using session state at all costs but it can certainly make things much easier to do. You shouldn't have much issues with it if you keep it as small as possible. Basically you eat up, on the server, the amount of memory consumed in session state X the number of concurrent users.

ViewState will only carry state accross a post versus session state which carries state the entire time a session is active. ViewState is carried to and from the client on each page cycle basically causing more data to traverse the connection. Again this is nice but can get quite large depending on what you are doing.
There are no steadfast rules, I hope this provides you some food for thought.
Mike Schellenberger - MCAD
0
schellem
3/24/2004 12:01:39 PM
Reply:

Similar Artilces:

Unable to use session state server....requires session state server version 2.0 or above.
So, I have Windows 2003 IIS latest service packs running. Its running .NET 2.0 and .NET 1.1 applications in seperate application pools. Just today I applied the following patch to the server. (The server is not running any 3.0 or 3.5 applications or application pools)  Microsoft .NET Framework 3.5 Service Pack 1 and .NET Framework 3.5 Family Update (KB951847) x86 Microsoft .NET Framework 3.5 Service Pack 1 is a full cumulative update that contains many new features building incrementally upon .NET Framework 2.0, 3.0, 3.5, and includes cumulative servicing upda...

Good news for those of you who get "Unable to make the session state request to the session state server." error..
Dear all,Due to the known problem of session variables getting lost if using InProc-server during frequent changes in development, I had to choose between SQL and ASP.NET State server, so I opted for the second. Initially, all fine, but after using it for a few days, I started to get this error: Server Error in '/cv2' Application.Unable to make the session state request to the session state server. Please ensure that the ASP.NET State service is started and that the client and server ports are the same.  If the server is on a remote machine, please ensure that it accep...

How to get new web app to use .NET 2.0 on Win2K server using .NET 1.1 as default framework?
I have .net framework1.1 and 2.0 on our server running win2K. i have existing applications that uses asp.net 1.1, i also have a new app that use ASP.net 2.0.  how can i set my new .NET 2.0 app to point to asp.net 2.0 without messing up my existing .NET 1.1 apps? To specify the ASP .Net version fro a web application, do the followingIn IIS Manager select the web application -> Properties -> ASP.Net TabSelect  ASP.Net version you want to use for the applicationRegards,PrashantDont forget to click "Mark as Answer" on the post that helped you. But I am running Win2K...

Use Read/Write or Read-Only Session State depending on GET or POST request
My web application is using the Post-Redirect-Get pattern and I use the Session state to store the state of the pages. I want to use an out-of-proc Session State store so the session state will be deserialized and serialized on every request. During a POST request to the page I want to have Read/Write access to the session state. During a GET request to the same page I want to have Read-Only access to the session state. Because the session state will not be altered during a GET request I do not want to write (and serialize) the session state at the end of the request (this is a time consu...

Get List of Online Users using (FormsAuth, Sql Session State, Cookies)
 Hi guys,I've been checking solutions for getting list of online users and all of the methods include ending the session with logging out, writing logged users in the database, or in some file. First, ending the session can be quite annoying (especially catching the 'Close' browser button in FireFox), and my session has hours of timeout so one user may have several sessions started if he didn't end his previous session for some reason. I think it's good to use the tables and stored procedures created by the aspnet_regsql.exe or some other built-in mechanism in ASP.NE...

how to get session data for array of checked items from checkbox to next page using vb.net
 Hi Im trying to pass session data values for  checked item's from checkbox's to next page on click. Here Im getting urlpath for selected checkbox items. How can i make it as array in session data and pass data to next page's.Any one plz its urgent. New to .Net   Protected Sub Page1_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles Page1.Click            Dim urlpath As String = Nothing            Dim alttext As String = Nothing &n...

Sending SMS using vb.net or C#.net using vb.net or c#.net
Hi  My requirement is I hav one csv file with these fields id,mobilenum,messgae,status.intiallu staus is 0. once i read the all fileds and take that mobile number.using tat mobile number  i need to send sms .after sending sms i shuld change status as 1 How to send sms thru coding (please dont provide any links.if it is provide also please give working links becox i checked codeproject .i didnt get any nice link. and also provide the how to update the status field im csv file   Thank ssandhya   To send SMS, you need some third party SMS providers. if you consul...

Session.SessionID, if it uses session state, why put it in the URL?
Hi,I have a website which uses Session.SessionID as a key, to lookup information about the user in my database (essentially managing state from page to page). I'm trying to make my site web-farmable and am having issues. It seems I can no longer user Session.SessionID to identify a user because it uses 'Session State' which is a no go on webfarm. I am aware that if the user has cookies turned on, it's all good, but I want users with cookies turned off to also be able to use my site.What confuses me is when cookies are turned off and a user browses my site, the SessionID appea...

Using session states
Aim:to transfer data accross webpages using session statesI configured my web.config as<sessionState     cookieless="UseCookies" cookieName="job_SessionId"     regenerateExpiredSessionId="false"   timeout="20" mode="InProc"     stateConnectionString="tcpip=127.0.0.1:42424" sqlConnectionString="data source=127.0.0.1;Integrated Security=SSPI"  stateNetworkTimeout="10"  sqlCommandTimeout="30" allowCustomSqlDat...

using session states
Hi, Well I am slowly progressing with my project, thanks everyone for helping me, I can explain to you now my next step: I have a form page with loads of fields(around 50) a mix of ddl's, text fields, checkboxes etc. that the user fills in e.g. to list ingredients and prices for a new article. From this I have created a dataset to hold all the info. Then I also have another page that is a datagrid that lists a summary of the users articles using the dataset but only a few of the fields, when the user wants to edit a row in the table they will get redirected back to...

Getting Started with Sessions
Hello All,Hopefully someone can help me out with this, its been driving me nuts for a few days now and being new to ASP I'm not sure where to look. Basically I am trying to share some data between 2 pages and for some reason the information is not coming across. - This is programmed in VB, in a code behind page.In page 1's page load event            Session("reportArray") = reportArray            Session("reportCounter") = reportCounter        ...

how to get start with .NET
the net help people installed  to my desktop 1-microsoft visual studio .NET enterprise developer 2003 2-microsoft .NET framework 1.1 what else do i need ...???  and how can i try with some simple code in VS.Net and run it to see wat happen...????? please help If you want to develope web applications, then you'll also need IIS on your PC.  That'll require XP-Professional or Windows 2000/2003, but XP-Home edition won't allow IIS installation. As for how to get started, you can search the web for some tutorials or buy a good book on VS.  The topic is way too vast to...

used a c#.net to vb.net converter and am now getting a syntax error.
ok I used a cool utility at http://www.kamalpatel.net/ConvertCSharp2VB.aspx to convert some c#.net to vb.net and it spit out a bunch of code which almost works but I am getting a syntax error on this line Imports (StreamReader sr = Shadows Function)() As StreamReader(objResponse.GetResponseStream()) I tried it that way and also like Imports (StreamReader sr = Shadows Function)() As StreamReader(objResponse.GetResponseStream()) but either way gave the same error Compiler Error Message: BC30035: Syntax error. Source Error: Line 26: Line ...

Getting Start With .net
hi i'm intersted to learn asp.net (vb or delphi) . i programming with delphi6 but i'd like to tp know something about programming in internet specially with .net . i hear about microsoft.net with delphi 7 that i can programming with delphi in .net .... is it right ? what 's our opinian about it ? and better to learn Vb.Net or continu with delphi(or delphi.net) thanks. Ali Darabian I think there is some support for Delphi in .Net. However, you will find much more support from the user community if you choose a more popular language such as VB.Net or C#. Since your al...

Web resources about - Session State - Should I use it? - asp.net.getting-started

Barack Obama speech to joint session of Congress, February 2009 - Wikipedia, the free encyclopedia
Obama's first State of the Union Address was the 2010 State of the Union Address . The speech was delivered on the floor of the chamber of the ...

Rona Ambrose Kicks Off National Tour Ahead Of Parliament's Winter Session 0
While the Liberals and New Democrats have strategy sessions planned, the Conservatives are taking a different approach.

The Logic Pros: 3 overlooked tricks to keep your Logic sessions tidy and efficient
In this week’s episode of The Logic Pros , we will be taking a look at three handy little tricks to keep things moving, a little more tidy and ...

Is this the world’s first full virtual-reality motion/voice capture session?
Actors combine mo-cap suit, HTC Vive to become characters, see virtual teleprompters. Forget latex suits and white ping-pong balls. Motion-capture ...

PAUL RYAN WHINES: Cruz and Sessions Lying About Omnibus Funding New Wave of Muslim Migration
By Julia Hahn In a Tuesday morning interview with radio host Bill Bennett, House Speaker Rep. Paul Ryan (R-WI) implied that prominent conservative ...

Comment at the URPE-AEA Session: Causes of the Great Recession and the Prospects for Recovery
Notes for My Comment at the URPE-AEA Session: [Causes of the Great Recession and the Prospects for Recovery][a] * Presiding: Fred Moseley * David ...

Bonnie 'Prince' Billy releasing compilation of Peel Sessions, shares new version of "Rich Wife Full of ...
by Andrew Sacher Bonnie 'Prince' Billy (aka Will Oldham) is releasing Pond Scum on January 22 via Drag City. It's a collection of Peel Sessions ...

Venkaiah Naidu attacks Chidambaram, hopes GST passes in Budget session
Naidu alleged that as per the 'script', the Congress was 'dodgy' on this important issue

Saturday Sessions: Aoife O’Donovan performs “The King of All Birds” - Videos - CBS News
The singer and songwriter graduated from the New England Conservatory of Music in her native Boston, and after singing with a progressive bluegrass ...

Orrin Evans Searches for 'The Evolution of Oneself,' Smoke Sessions Records (REVIEW)
It's a Philly thing, man. It's also a family thing. For his 26th album, pianist Orrin Evans has formed his dream trio.

Resources last updated: 1/19/2016 4:58:45 AM