Topic #
Up To: Diagrams
   Open: Dynamic Sites  
   Read: Static Sites  
   Read: WebHub White Paper  

to to to to Sessions

Browsing >>Sessions: Management of Surfer Session Data

WebHub's architecture includes a session object, in which details about the site visitor are kept. Those details may include data entered on forms, information sent by the browser such as user agent name and various headers, page usage counts, and so on.

The Hub assigns each visitor a unique session number, and that session number is visible in the URL and/or in a cookie. Uniqueness is enforced relative to a time period which is set by the administrator, defaulting to 24 hours and often shortened to 30 minutes. Within that time period, each new visitor is given a unique number. The administrator also sets the number of digits in the session number (between 4 and 10, inclusive), and this factors into the size of the pool of session numbers. A higher number of digits gives more unique numbers.

The session data is stored in memory in an object named "Session" plus the session number, such as "Session12345". This data is streamed to disk using Delphi's component-write streaming, which is highly optimized. The programmer decides how many session objects to retain in memory at any one point in time. The default is 300.

When there are multiple instances of a WebHub application running, and visitors are not being routed to the same instance each time (i.e. the cgiUseHandle property is false), the session data can be shared across those instances because each loads the data from disk as needed. This type of sharing is enabled by setting two properties, ShareByFile and ShareSessions, both to true.

There is some disk i/o and other overhead in creating a new session, relative to reusing an existing one. Therefore when stress testing WebHub systems, it is important to consciously test (a) all new, (b) all active, or (c) a mixture of active and new session numbers.

Running: WebHub-v3.271 compiled with d25_win32 on Microsoft-IIS/10.0,
Fri, 23 Feb 2018 02:32:41 UTC
Session 1259337104, 0 pages sent to CCBot/2.0 (http://commoncrawl.org/faq/) at;
Time to produce this page: 31msec.