Class ChangeDetailPruningPersistenceMessageAckedHandler
java.lang.Object
com.broadleafcommerce.data.tracking.core.messaging.ChangeDetailPruningPersistenceMessageAckedHandler
- All Implemented Interfaces:
com.broadleafcommerce.common.extension.data.DataRoutePartitionAware
,com.broadleafcommerce.common.messaging.PersistenceMessageAckedHandler
,org.springframework.core.Ordered
public class ChangeDetailPruningPersistenceMessageAckedHandler
extends Object
implements com.broadleafcommerce.common.messaging.PersistenceMessageAckedHandler
This component prunes the change details from production-level
Trackable
entities
following successful acknowledgement of the PersistenceMessage
's notification state.
For sandboxable entities, the Tracking.getLevel()
must be
TrackingLevel.PRODUCTION
. All non-sandboxable entities are implicitly considered
production-level.
- Author:
- Samarth Dhruva (samarthd)
-
Field Summary
Fields inherited from interface com.broadleafcommerce.common.extension.data.DataRoutePartitionAware
ALL_MATCH
Fields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
afterSuccessfulAcknowledgement
(Object nativeId, com.broadleafcommerce.common.messaging.notification.domain.NotificationStateAware notificationStateAware, com.broadleafcommerce.common.messaging.notification.NotificationStateRepository repository) protected boolean
isProductionLevel
(Trackable trackable) protected boolean
isSandboxableEntity
(Trackable trackable, TrackableBehaviorUtil trackableBehaviorUtil) protected boolean
isTrackable
(com.broadleafcommerce.common.messaging.notification.domain.NotificationStateAware notificationStateAware) protected boolean
isTrackableRepository
(com.broadleafcommerce.common.messaging.notification.NotificationStateRepository repository) protected void
pruneChangeDetails
(Object nativeEntityId, TrackableRepository<Trackable> repository) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.broadleafcommerce.common.messaging.PersistenceMessageAckedHandler
getOrder
-
Constructor Details
-
ChangeDetailPruningPersistenceMessageAckedHandler
public ChangeDetailPruningPersistenceMessageAckedHandler()
-
-
Method Details
-
afterSuccessfulAcknowledgement
public void afterSuccessfulAcknowledgement(@NonNull Object nativeId, @NonNull com.broadleafcommerce.common.messaging.notification.domain.NotificationStateAware notificationStateAware, @NonNull com.broadleafcommerce.common.messaging.notification.NotificationStateRepository repository) - Specified by:
afterSuccessfulAcknowledgement
in interfacecom.broadleafcommerce.common.messaging.PersistenceMessageAckedHandler
-
isTrackable
protected boolean isTrackable(com.broadleafcommerce.common.messaging.notification.domain.NotificationStateAware notificationStateAware) -
isTrackableRepository
protected boolean isTrackableRepository(com.broadleafcommerce.common.messaging.notification.NotificationStateRepository repository) -
isSandboxableEntity
protected boolean isSandboxableEntity(Trackable trackable, TrackableBehaviorUtil trackableBehaviorUtil) -
isProductionLevel
-
pruneChangeDetails
-
getDataRoutePartition
- Specified by:
getDataRoutePartition
in interfacecom.broadleafcommerce.common.extension.data.DataRoutePartitionAware
-