Online documentation - Websydian v6.0

Users Guide | Patterns Reference | WebsydianExpress | Search

 

The Session Management Module

Library

WSYSESS

Main Pattern

SessionControl

Introduction to the Session Management Module

Current Web Technology has the inherent problem that there is no notion of a User Session when someone is accessing a web site: By default, the Web Server Software does not systematically register which users are accessing what pages, or in what sequence.  It simply handles a sequence of seemingly unrelated requests.

In some web applications, the lack of User Sessions is not a problem, simply because there is no need to restrict access to certain areas, to personalize the viewed pages, or to log specific user actions.

However, in most web applications there is such a need.  If, for example, you are building an Internet Shopping Application, in which the users can put items in a shopping cart while they go through the shop looking at the items for sale, then you will need to keep track of the various users' shopping carts.  When you receive a request to put something in the shopping cart you must know into which shopping cart it should be put.  That is equivalent to knowing from which Session the request came.

Session Control in Websydian

In the Session module, Session control is implemented by a SessionControl pattern containing a single Session table containing Session record for each User Session created by the application.  Whenever a new web user enters the application, a new record is created with a Session ID, a Session Status, an IP address of the web user, timestamps for creation and last request and a request count.

Once the Session is established, the Session ID will be sent back and forth as a hidden field in all subsequent interaction with the web user and the Websydian application will now be able to keep track of the individual Sessions.

The same web user may initiate several Sessions depending on how many times he calls the entrance page of the application.