Package io.quarkus.hibernate.envers
Class HibernateEnversBuildTimeConfigPersistenceUnit
- java.lang.Object
-
- io.quarkus.hibernate.envers.HibernateEnversBuildTimeConfigPersistenceUnit
-
public class HibernateEnversBuildTimeConfigPersistenceUnit extends Object
-
-
Field Summary
Fields Modifier and Type Field Description Optional<Boolean>
active
Whether Hibernate Envers should be active for this persistence unit at runtime.boolean
allowIdentifierReuse
Enables the allow_identifier_reuse feature.Optional<String>
auditStrategy
Defines the fully qualified class name of the audit strategy to be used.Optional<String>
auditStrategyValidityEndRevFieldName
Defines the column name that holds the end revision number in audit entities.Optional<String>
auditStrategyValidityRevendTimestampFieldName
Defines the column name of the revision end timestamp in the audit tables.boolean
auditStrategyValidityStoreRevendTimestamp
Enables the audit_strategy_validity_store_revend_timestamp feature.Optional<String>
auditTablePrefix
Defines a prefix for historical data table.Optional<String>
auditTableSuffix
Defines a suffix for historical data table.Optional<String>
defaultCatalog
Defines the default catalog of where audit tables are to be created.Optional<String>
defaultSchema
Defines the default schema of where audit tables are to be created.boolean
doNotAuditOptimisticLockingField
Enable the do_not_audit_optimistic_locking_field feature.Optional<String>
embeddableSetOrdinalFieldName
Defines the name of the column used for storing collection ordinal values for embeddable elements.boolean
globalWithModifiedFlag
Enables the global_with_modified_flag feature.Optional<String>
modifiedColumnNamingStrategy
Defines the naming strategy to be used for modified columns.Optional<String>
modifiedFlagSuffix
Defines the suffix to be used for modified flag columns.Optional<String>
originalIdPropName
Defines the property name for the audit entity's composite primary key.Optional<String>
revisionFieldName
Revision field name.Optional<String>
revisionListener
Defines the fully qualified class name of a user defined revision listener.boolean
revisionOnCollectionChange
Enable the revision_on_collection_change feature.Optional<String>
revisionTypeFieldName
Revision type field name.boolean
storeDataAtDelete
Enable store_data_at_delete feature.boolean
trackEntitiesChangedInRevision
Enables the track_entities_changed_in_revision feature.boolean
useRevisionEntityWithNativeId
Enables the use_revision_entity_with_native_id feature.
-
Constructor Summary
Constructors Constructor Description HibernateEnversBuildTimeConfigPersistenceUnit()
-
-
-
Field Detail
-
active
@ConfigItem(defaultValueDocumentation="\'true\' if Hibernate ORM is enabled; \'false\' otherwise") public Optional<Boolean> active
Whether Hibernate Envers should be active for this persistence unit at runtime. If Hibernate Envers is not active, the audit entities will *still* be added to the Hibernate ORM metamodel and to the database schema that Hibernate ORM generates: you would need to disable Hibernate Envers at build time (i.e. set `quarkus.hibernate-envers.enabled` to `false`) in order to avoid that. However, when Hibernate Envers is not active, it will not process entity change events nor create new versions of entities. and accessing the AuditReader through AuditReaderFactory will not be possible. Note that if Hibernate Envers is disabled (i.e. `quarkus.hibernate-envers.enabled` is set to `false`), it won't be active for any persistence unit, and setting this property to `true` will fail.
-
storeDataAtDelete
@ConfigItem(defaultValue="false") public boolean storeDataAtDelete
Enable store_data_at_delete feature. Maps toEnversSettings.STORE_DATA_AT_DELETE
.
-
auditTableSuffix
@ConfigItem(defaultValue="_AUD") public Optional<String> auditTableSuffix
Defines a suffix for historical data table. Defaults to _AUD. Maps toEnversSettings.AUDIT_TABLE_SUFFIX
.
-
auditTablePrefix
@ConfigItem(defaultValue="") public Optional<String> auditTablePrefix
Defines a prefix for historical data table. Default is the empty string. Maps toEnversSettings.AUDIT_TABLE_PREFIX
.
-
revisionFieldName
@ConfigItem(defaultValue="REV") public Optional<String> revisionFieldName
Revision field name. Defaults to REV. Maps toEnversSettings.REVISION_FIELD_NAME
.
-
revisionTypeFieldName
@ConfigItem(defaultValue="REVTYPE") public Optional<String> revisionTypeFieldName
Revision type field name. Defaults to REVTYPE. Maps toEnversSettings.REVISION_TYPE_FIELD_NAME
.
-
revisionOnCollectionChange
@ConfigItem(defaultValue="true") public boolean revisionOnCollectionChange
Enable the revision_on_collection_change feature. Maps toEnversSettings.REVISION_ON_COLLECTION_CHANGE
.
-
doNotAuditOptimisticLockingField
@ConfigItem(defaultValue="true") public boolean doNotAuditOptimisticLockingField
Enable the do_not_audit_optimistic_locking_field feature. Maps toEnversSettings.DO_NOT_AUDIT_OPTIMISTIC_LOCKING_FIELD
.
-
defaultSchema
@ConfigItem(defaultValue="") public Optional<String> defaultSchema
Defines the default schema of where audit tables are to be created. Maps toEnversSettings.DEFAULT_SCHEMA
.
-
defaultCatalog
@ConfigItem(defaultValue="") public Optional<String> defaultCatalog
Defines the default catalog of where audit tables are to be created. Maps toEnversSettings.DEFAULT_CATALOG
.
-
trackEntitiesChangedInRevision
@ConfigItem(defaultValue="false") public boolean trackEntitiesChangedInRevision
Enables the track_entities_changed_in_revision feature. Maps toEnversSettings.TRACK_ENTITIES_CHANGED_IN_REVISION
.
-
useRevisionEntityWithNativeId
@ConfigItem(defaultValue="true") public boolean useRevisionEntityWithNativeId
Enables the use_revision_entity_with_native_id feature. Maps toEnversSettings.USE_REVISION_ENTITY_WITH_NATIVE_ID
.
-
globalWithModifiedFlag
@ConfigItem(defaultValue="false") public boolean globalWithModifiedFlag
Enables the global_with_modified_flag feature. Maps toEnversSettings.GLOBAL_WITH_MODIFIED_FLAG
.
-
modifiedFlagSuffix
@ConfigItem(defaultValue="_MOD") public Optional<String> modifiedFlagSuffix
Defines the suffix to be used for modified flag columns. Defaults to _MOD. Maps toEnversSettings.MODIFIED_FLAG_SUFFIX
-
revisionListener
@ConfigItem public Optional<String> revisionListener
Defines the fully qualified class name of a user defined revision listener. Maps toEnversSettings.REVISION_LISTENER
.
-
auditStrategy
@ConfigItem(defaultValue="org.hibernate.envers.strategy.DefaultAuditStrategy") public Optional<String> auditStrategy
Defines the fully qualified class name of the audit strategy to be used. Maps toEnversSettings.AUDIT_STRATEGY
.
-
originalIdPropName
@ConfigItem(defaultValue="originalId") public Optional<String> originalIdPropName
Defines the property name for the audit entity's composite primary key. Defaults to originalId. Maps toEnversSettings.ORIGINAL_ID_PROP_NAME
.
-
auditStrategyValidityEndRevFieldName
@ConfigItem(defaultValue="REVEND") public Optional<String> auditStrategyValidityEndRevFieldName
Defines the column name that holds the end revision number in audit entities. Defaults to REVEND. Maps toEnversSettings.AUDIT_STRATEGY_VALIDITY_END_REV_FIELD_NAME
.
-
auditStrategyValidityStoreRevendTimestamp
@ConfigItem(defaultValue="false") public boolean auditStrategyValidityStoreRevendTimestamp
Enables the audit_strategy_validity_store_revend_timestamp feature. Maps toEnversSettings.AUDIT_STRATEGY_VALIDITY_STORE_REVEND_TIMESTAMP
.
-
auditStrategyValidityRevendTimestampFieldName
@ConfigItem(defaultValue="REVEND_TSTMP") public Optional<String> auditStrategyValidityRevendTimestampFieldName
Defines the column name of the revision end timestamp in the audit tables. Defaults to REVEND_TSTMP. Maps toEnversSettings.AUDIT_STRATEGY_VALIDITY_REVEND_TIMESTAMP_FIELD_NAME
.
-
embeddableSetOrdinalFieldName
@ConfigItem(defaultValue="SETORDINAL") public Optional<String> embeddableSetOrdinalFieldName
Defines the name of the column used for storing collection ordinal values for embeddable elements. Defaults to SETORDINAL. Maps toEnversSettings.EMBEDDABLE_SET_ORDINAL_FIELD_NAME
.
-
allowIdentifierReuse
@ConfigItem(defaultValue="false") public boolean allowIdentifierReuse
Enables the allow_identifier_reuse feature. Maps toEnversSettings.ALLOW_IDENTIFIER_REUSE
.
-
modifiedColumnNamingStrategy
@ConfigItem(defaultValue="org.hibernate.envers.boot.internal.LegacyModifiedColumnNamingStrategy") public Optional<String> modifiedColumnNamingStrategy
Defines the naming strategy to be used for modified columns. Defaults to org.hibernate.envers.boot.internal.LegacyModifiedColumnNamingStrategy. Maps toEnversSettings.MODIFIED_COLUMN_NAMING_STRATEGY
.
-
-