Class FastSessionServices

java.lang.Object
org.hibernate.internal.FastSessionServices

public final class FastSessionServices extends Object
Internal component.

Collects any components that any Session implementation will likely need for faster access and reduced allocations. Conceptually this acts as an immutable caching intermediary between Session and SessionFactory.

Designed to be immutable, shared across Session instances, and created infrequently, possibly only once per SessionFactory.

If the Session is requiring to retrieve (or compute) anything from the SessionFactory, and this computation would result in the same outcome for any Session created on this same SessionFactory, then it belongs in a final field of this class.

Finally, consider also limiting the size of each Session: some fields could be good candidates to be replaced with access via this object.