public interface CurrentTenantIdentifierResolver
A callback registered with the SessionFactory that is responsible for resolving the
current tenant identifier for use with CurrentSessionContext and
SessionFactory.getCurrentSession()
| Modifier and Type | Method and Description |
|---|---|
String |
resolveCurrentTenantIdentifier()
Resolve the current tenant identifier.
|
boolean |
validateExistingCurrentSessions()
Should we validate that the tenant identifier on "current sessions" that already exist when
CurrentSessionContext.currentSession() is called matches the value returned here from
resolveCurrentTenantIdentifier()? |
String resolveCurrentTenantIdentifier()
Resolve the current tenant identifier.
boolean validateExistingCurrentSessions()
Should we validate that the tenant identifier on "current sessions" that already exist when
CurrentSessionContext.currentSession() is called matches the value returned here from
resolveCurrentTenantIdentifier()?
true indicates that the extra validation will be performed; false indicates it will not.TenantIdentifierMismatchExceptionCopyright © 2001-2018 Red Hat, Inc. All Rights Reserved.