aspx Tutorial

NET Articles,jQuery demo, with jQuery, online tutorial,Jquery, SilverLight, Javascript,,JSON, MVC,.NET Articles,demo, Web Services,
Advertise Here


Get our toolbar!


Posted by Aamir Hasan   on Sunday, August 22, 2010 Total Views:  

Session is a server side state management technique in ASP.NET. ASP.NET 4.O provide build in support for compress and decompress serialized Session state, By using this compress session state, you can improve your server performance. Compress option can be used when you are storing large amount of data in Session this will reduce the size of session. Session data can be stored in following two modes.

  1. In Process
    • Store in the same ASP.NET Process
  2. Out of Process
    • Store in Data base.

To enable this feature, you have to set compressionEnable attribute to ture in Session State settings in Web.config.

I have created a Web Site in Visual Studio 2010 as i will consider you know how to create a web site in Visual Studio 2010.

Now i have stored some text in Sessions as shown in below Figure 1.1

Figure 1.1

Enable compressionEnabled= "true" in Session State of your Web.Config file as shown in below Figure 1.2

Figure 1.2

Now Load this Page and you will see the out put as i have shown in Figure 1.2

Figure 1.3

Disable compressionEnabled= "false" in Session State of your Web.Config file as shown in below Figure 1.4


Figure 1.4

Now Load your page, you will see the Begin Render and End Render time as shown in below Figure 1.5

Figure 1.5

This example shows that using ASP.NET 4.O new feature you can reduce the work load of your server but this will be effected when you are storing large amount of data.


Compress Session State  in ASP.NET 4.O



Category: All | ASP.NET 4.O
Protected by Copyscape Online Plagiarism Tool

Comments (1) -

ray ban uk
ray ban uk People's Republic of China
11/7/2012 8:16:02 PM #

It really is significant to speak about exactly where holidays will choose location and which traditions they will choose to celebrate.

Add comment

  Country flag

  • Comment
  • Preview

Advertizement 1
Advertizement 2
Advertizement 3
Advertizement 4
Advertizement 5