Class DetachedBackendSessionContext


@Deprecated public final class DetachedBackendSessionContext extends Object
SPIs should simply pass around a string representing the tenant ID instead of using this class. In cases where the mapping context is also necessary, it should be passed around as a separate parameter.
Provides visibility from the lower layers of Hibernate Search (engine, backend) to the session defined in the upper layers (mapping).

On contrary to BackendSessionContext, this context is expected to be detached from the actual session, allowing it to be used after the session was closed. The main downside is that this context cannot be used everywhere BackendSessionContext can. In particular, it cannot be used when creating document-related indexing plans or indexers because these may need access to the session.