@Service public class UniqueIdGenerator extends Object implements org.hibernate.id.IdentifierGenerator
| Modifier and Type | Field and Description |
|---|---|
static InternalDataBaseSqlExecutor |
INTERNAL_DATABASE_SQL_EXECUTOR |
| Constructor and Description |
|---|
UniqueIdGenerator() |
UniqueIdGenerator(InternalDataBaseSqlExecutor internalDataBaseSqlExecutor) |
| Modifier and Type | Method and Description |
|---|---|
static Serializable |
generate()
Get next BigInteger id from pool.
|
Serializable |
generate(org.hibernate.engine.spi.SharedSessionContractImplementor sharedSessionContractImplementor,
Object o)
Hibernate is using this method to get ids (UniqueIdGenerator is set as id generator in hibernate mapping).
|
static Serializable |
generateReportingId()
Get next BigInteger id from pool, for reporting objects (messages, contexts etc.).
|
public static InternalDataBaseSqlExecutor INTERNAL_DATABASE_SQL_EXECUTOR
public UniqueIdGenerator()
@Autowired public UniqueIdGenerator(InternalDataBaseSqlExecutor internalDataBaseSqlExecutor)
public static Serializable generate()
public Serializable generate(org.hibernate.engine.spi.SharedSessionContractImplementor sharedSessionContractImplementor, Object o) throws org.hibernate.HibernateException
generate in interface org.hibernate.id.IdentifierGeneratorsharedSessionContractImplementor - sharedSessionContractImplementor.o - object.org.hibernate.HibernateException - if Hibernate can't get\generate id via getNextIdFromQueue() method.public static Serializable generateReportingId()
Copyright © 2025. All rights reserved.