JSP Session Tracking - If a web application is capable of remembering a client data during a session across the multiple requests then that web application is called as a stateful Web application. Even though HTTP is a stateless protocol, web applications should be made as stateful web applications. For this, working with the following session tracking or session management techniques is necessary.
- Hidden Form fields
- HTTP Cookies
- Session ID
- HTTP session with URL rewriting
JSP Session Tracking - A web server can send a hidden HTML structure field alongside a unique session ID as follows.
[java]<input type="hidden" name="sessionid" value="54321">[/java]
at the point when the form is presented, the predetermined name and value are consequently incorporated into the GET or POST information. Every time when web program sends request back, then session_id value can be utilized to monitor distinctive web programs.
JSP Session Tracking - A webserver can relegate a one of a kind
session ID as a treat to every web browser and for resulting requests from the client they can be perceived utilizing the got cookie. This may not be a successful way on the grounds that numerous time program does not bolster a cookie.
JSP Session Tracking - One can add some additional information on the end of every URL that distinguishes the session, and the server can relate that session identifier with information it has put away about that session.
URL Rewriting is a superior approach to keep up sessions and works for the programs when they don't support cookies yet here downside is that you would have produce each URL powerfully to allocate a session ID however page is basic static HTML page.
JSP Session Tracking - JSP makes utilization of servlet gave HttpSession Interface which gives an approach to distinguish a client crosswise over more than one page request or visit to a Web webpage and to store data about that client.
Of course, JSPs have session tracking empowered and another HttpSession object is instantiated for each new client consequently. Incapacitating session following requires unequivocally turning it off by setting the page order session credit to false as follows.
[java]<%@ page session="false" %>[/java]
Session tracking is all about making web application as a stateful web application by remembering client data across the multiple requests during a session. Following are the RealTime Implementation of session tracking/session management. Following is the servlet session tracking link.
Servlet Session Tracking