The SessionIdGenerator Component
Table of Contents
Introduction
The SessionIdGenerator element represents the session id generator that will be used to create session ids used by web application HTTP sessions.
A SessionIdGenerator element MAY be nested inside a Manager component. If it is not included, a default SessionIdGenerator configuration will be created automatically, which is sufficient for most requirements, — see Standard SessionIdGenerator Implementation below for the details of this configuration.
Attributes
Common Attributes
All implementations of SessionIdGenerator support the following attributes:
| Attribute | Description | 
|---|---|
| className | Java class name of the implementation to use.  This class must
        implement the  | 
| jvmRoute | A routing identifier for this Tomcat instance. It will be added
        to the session id to allow for stateless stickiness routing by
        load balancers. The details on how the  NOTE - The value for this property is inherited
        automatically from the  | 
| sessionIdLength | The length of session ids created by this SessionIdGenerator.
        The details on how the  | 
Standard Implementation
Tomcat provides a standard implementations of SessionIdGenerator for use.
Standard SessionIdGenerator Implementation
The standard implementation of SessionIdGenerator is org.apache.catalina.util.StandardSessionIdGenerator. It supports the following attributes:
| Attribute | Description | 
|---|---|
| jvmRoute | A routing identifier for this Tomcat instance. It will be added to the end of the session id separated by a ".". | 
| sessionIdLength | The length of session ids created by this SessionIdGenerator.
        More precisely the session id length is twice the value of
         | 
