ASP.NET State management


Published on

This PPT explains about the various ways to manage the state of an web application. This PPT is for complete beginners and intermediate developers who want to know few things about State Management. Here I have explained in brief about the various techniques we use to manage the state of our application.

Published in: Technology
  • Be the first to comment

No Downloads
Total Views
On Slideshare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

ASP.NET State management

  1. 1.  Introduction of State Management Types of State Management  Client Side Techniques  Server Side Techniques Client Side State Management  (Introduction and Ways) Server Side State Management  (Introduction and Ways)
  2. 2.  Http is a stateless protocol. Web Server does not have any idea about the requests. Example – Online Registration Form
  3. 3.  Client Side State Management  Utilizes Clients Resources  Ways : View state, Hidden fields, Query string, Cookies Server Side State Management  Utilizes Server Resources  Ways : Session State, Application State.
  4. 4. Client Side State Management View State –  It stores information submitted through form and works between requests of the same page.  The values written in the server control is passed as a variable to an HTML hidden input field. Advantages 1. No Server resources required. 2. Simple Implementation Disadvantages 1. Performance Consideration 2. Potential Security risks
  5. 5.  Hidden Fields –  Can be used to store page specific information  Can be used to store small amount of data Advantages 1. No Server resources are required 2. Widespread Support 3. Simple Implementation Disadvantages 1. Performance Considerations 2. Potential Security (If Page O/P Source is viewed)
  6. 6.  Query String –  A String which is appended to the end of the page URL.  Can be used to send small amount of data and if security is not a concern  Can be used to pass small amount of data from 1 page to another. Advantages 1. No Server side resources used. 2. Simple implementation Disadvantages 1. Limited Capacity 2. Potential Security risk
  7. 7.  Cookies –  It is useful to store small amount of data on the Client side.  It can be temporary(with specific expiration time and date). Advantages 1. Configurable Expiration Rules 2. No Server Resources required 3. Simplicity Disadvantages 1. Size limitations 2. User-configured refusal 3. Less Secured
  8. 8. Server Side State Management Session State –  Stored in the Server’s memory and value can be accessed across page requests.  3 different modes of storing the Sessions.  InProc  State Server  SQL Server  Off  Advantages  Cookieless Support  Data Persistence  Disadvantages  Performance Consideration
  9. 9.  Application State  It is used to store global application specific information  Automatically created when a first request is made to a web application  Storing application state in the Server’s memory is better than storing the information in the database Advantages 1. Application Scope 2. Simple Implementation Disadvantages 1. Requires Server resources 2. Limited Durability of data (Server Crash or Shutdown)
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.