Class DataFeedUtils
java.lang.Object
com.broadleafcommerce.data.tracking.jpa.datafeed.DataFeedUtils
Provides useful utility functions related to data feed flows
-
Method Summary
Modifier and TypeMethodDescriptionstatic List<com.broadleafcommerce.data.tracking.core.filtering.domain.ChangeDetail>
filterProductionDetails
(List<com.broadleafcommerce.data.tracking.core.filtering.domain.ChangeDetail> originalDetails) FilterChangeDetail
instances to a candidate subset of possible details to consider for data feed incremental notification.static Instant
getEventTime
(List<com.broadleafcommerce.data.tracking.core.filtering.domain.ChangeDetail> originalDetails) Get a timestamp from the most recent set of production update changes, if available.
-
Method Details
-
filterProductionDetails
public static List<com.broadleafcommerce.data.tracking.core.filtering.domain.ChangeDetail> filterProductionDetails(@Nullable List<com.broadleafcommerce.data.tracking.core.filtering.domain.ChangeDetail> originalDetails) FilterChangeDetail
instances to a candidate subset of possible details to consider for data feed incremental notification. This generally includes limiting to only the most recent production update changes.- Parameters:
originalDetails
- The original set of unfiltered change details- Returns:
- The filtered set of change details
-
getEventTime
public static Instant getEventTime(@Nullable List<com.broadleafcommerce.data.tracking.core.filtering.domain.ChangeDetail> originalDetails) Get a timestamp from the most recent set of production update changes, if available. Otherwise, simply return now.- Parameters:
originalDetails
- The original set of unfiltered change details- Returns:
- A timestamp from the most recent set of production update changes, if available. Otherwise, return now.
-