Class AuditEventHeader
java.lang.Object
com.broadleafcommerce.common.audit.domain.AuditEventHeader
- All Implemented Interfaces:
Serializable
Header information for an audit record. Also supports the builder pattern by using
AuditEventHeader.builder()
.- See Also:
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionAuditEventHeader
(@NonNull Instant timestamp, String entityType, String entityRef, String customerid, String accountid, @NonNull String tenantId, String catalogId, String applicationId, @NonNull String detailType, Map<String, String> additionalAttributes, Duration retentionPeriod, @NonNull String eventType, String containerEventType, String containerRef, String primaryAuthor, String secondaryAuthor) -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
protected boolean
boolean
Identifier for an account entity.Any additional information, possibly required in extension scenarios.The application to which this audit record belongs.The catalog to which this audit record belongs.In the case ofTrackable
entity change, The name of the containing entity, which is typically snake-cased and capitalized, i.e., "PRODUCT".Identifying reference to the containing entity.Identifier for a customer entity.The type of detail information associated with this audit event.Identifying reference to the entity.Fully qualified class name of the top-level entity being changed.In the case ofTrackable
entity change, The name of the top-level entity that changed, which is typically snake-cased and capitalized, i.e., "PRODUCT".The primary author of the change.Optional.Any additional author for the change.The tenant to whom this audit record belongs.The time at which the change was reported to the system.int
hashCode()
toString()
-
Constructor Details
-
AuditEventHeader
public AuditEventHeader(@NonNull @NonNull Instant timestamp, @Nullable String entityType, @Nullable String entityRef, @Nullable String customerid, @Nullable String accountid, @NonNull @NonNull String tenantId, @Nullable String catalogId, @Nullable String applicationId, @NonNull @NonNull String detailType, @Nullable Map<String, String> additionalAttributes, @Nullable Duration retentionPeriod, @NonNull @NonNull String eventType, @Nullable String containerEventType, @Nullable String containerRef, @Nullable String primaryAuthor, @Nullable String secondaryAuthor)
-
-
Method Details
-
builder
-
getTimestamp
The time at which the change was reported to the system. Required. -
getEntityType
Fully qualified class name of the top-level entity being changed. Optional. For audit changes to a particular entity. -
getEntityRef
Identifying reference to the entity. Usually a contextId for Trackable domain. Optional. For audit changes to a particular entity. -
getCustomerid
Identifier for a customer entity. Useful for identifying a customer related to the change. Optional. For audit events related to a customer. -
getAccountid
Identifier for an account entity. Useful for identifying an account related to the change. Optional. For audit events related to an account. -
getTenantId
The tenant to whom this audit record belongs. Required. -
getCatalogId
The catalog to which this audit record belongs. Optional. For audit events related to a catalog discriminated entity. -
getApplicationId
The application to which this audit record belongs. Optional. For audit events related to an application discriminated entity. -
getDetailType
The type of detail information associated with this audit event. SeeDetailType
. -
getAdditionalAttributes
Any additional information, possibly required in extension scenarios. Optional. -
getRetentionPeriod
Optional. The amount of time to keep this record in hot storage (i.e. searchable inAuditServices
). If set, will override the default retention period defined inAuditServices
. Seecom.broadleafcommerce.audit.env.AuditPruneProperties#retentionPeriod
inAuditServices
for the system default. -
getEventType
In the case ofTrackable
entity change, The name of the top-level entity that changed, which is typically snake-cased and capitalized, i.e., "PRODUCT". Arbitrary audit events may use this field to represent the type of event. Required. -
getContainerEventType
In the case ofTrackable
entity change, The name of the containing entity, which is typically snake-cased and capitalized, i.e., "PRODUCT". This is a grouping concept for correlating multiple related changes to a singular concept. For example, a marketing message change, which from the admin perspective looks like a change to an offer. Optional. -
getContainerRef
Identifying reference to the containing entity. Usually a contextId for Trackable domain. Optional. SeecontainerEventType
. -
getPrimaryAuthor
The primary author of the change. Optional. ForDetailType.CHANGE_DETAIL
events, this field generally represents the approver of the overall entity change. SeeAuditEventDetail.getAuthor()
for more specific ownership of field-level changes. For non-CHANGE_DETAIL events, this field represents the user driving the event. -
getSecondaryAuthor
Any additional author for the change. Optional. ForDetailType.CHANGE_DETAIL
events, this field generally represents the user engaged the deployment. For non-CHANGE_DETAIL events, this field represents any CSR impersonating the primary author for the event. -
equals
-
canEqual
-
hashCode
public int hashCode() -
toString
-