Class DataFeedPublication

java.lang.Object
com.broadleafcommerce.datafeed.domain.DataFeedPublication
All Implemented Interfaces:
com.broadleafcommerce.data.tracking.core.ContextStateAware, Serializable

public class DataFeedPublication extends Object implements Serializable, com.broadleafcommerce.data.tracking.core.ContextStateAware
This represents a 'sub-execution' within a DataFeedProcessExecution that is specifically interested in transforming data (which was already fetched in an earlier step of the execution) and publishing it for one specific DataFeedPublicationConfiguration.

Admin users should almost never be responsible for making direct CRUD requests on this entity. The system should be in charge of managing these records.

See Also:
  • Constructor Details

    • DataFeedPublication

      public DataFeedPublication()
  • Method Details

    • getId

      public String getId()
      The context ID of this publication.
      Returns:
      the id of this data feed publication
    • getDataFeedProcessExecutionId

      public String getDataFeedProcessExecutionId()
      The DataFeedProcessExecution.getId() of the DataFeedProcessExecution which this publication is for.
      Returns:
      the ID of the data feed process execution this publication is for
    • getApplicationId

      public String getApplicationId()
      Should be copied from DataFeedProcessExecution.getApplicationId().

      This may be useful for application filtration/visibility concerns specifically relating to DataFeedPublication.

      Returns:
      value matching DataFeedProcessExecution.getApplicationId()
    • getTargetDataFeedPublicationConfigurationId

      public String getTargetDataFeedPublicationConfigurationId()
      The DataFeedPublicationConfiguration.getId() of the DataFeedPublicationConfiguration that this publication process will publish data to.

      This will be one of the values from DataFeedProcessExecution.getDataFeedPublicationConfigurationIds().

      Returns:
      feed publication configuration ID that this publication will publish data to
    • getStartTime

      @Nullable public Instant getStartTime()
      The time at which this publication started processing.
      Returns:
      the time at which this publication started processing
    • getEndTime

      @Nullable public Instant getEndTime()
      The time at which this publication stopped processing.
      Returns:
      the time at which this publication stopped processing
    • getStatus

      public String getStatus()
      Should contain a value from DefaultDataFeedPublicationStatuses describing the current status of the publication.

      When this is being changed, be sure to update getStartTime() or getEndTime() if appropriate.

      Returns:
      the current status of the publication
    • isContainsErrors

      public boolean isContainsErrors()
      A simple flag indicating whether the current publication encountered any errors.
      Returns:
      whether this publication experienced errors
      See Also:
    • getErrorDetails

      public List<String> getErrorDetails()
      If errors are encountered during the run of this publication (ex: isContainsErrors() is true), details should be added here. Otherwise, this will be empty.
      Returns:
      details about any errors experienced by this publication
      See Also:
    • getContextState

      public com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextState getContextState()
      A subset of Tracking information to expose the context state for this object.
      Specified by:
      getContextState in interface com.broadleafcommerce.data.tracking.core.ContextStateAware
      Returns:
      a subset of Tracking information to expose the context state for this object
    • setId

      public void setId(String id)
      The context ID of this publication.
      Parameters:
      id - the id of this data feed publication
    • setDataFeedProcessExecutionId

      public void setDataFeedProcessExecutionId(String dataFeedProcessExecutionId)
      The DataFeedProcessExecution.getId() of the DataFeedProcessExecution which this publication is for.
      Parameters:
      dataFeedProcessExecutionId - the ID of the data feed process execution this publication is for
    • setApplicationId

      public void setApplicationId(String applicationId)
      Should be copied from DataFeedProcessExecution.getApplicationId().

      This may be useful for application filtration/visibility concerns specifically relating to DataFeedPublication.

      Parameters:
      applicationId - value matching DataFeedProcessExecution.getApplicationId()
    • setTargetDataFeedPublicationConfigurationId

      public void setTargetDataFeedPublicationConfigurationId(String targetDataFeedPublicationConfigurationId)
      The DataFeedPublicationConfiguration.getId() of the DataFeedPublicationConfiguration that this publication process will publish data to.

      This will be one of the values from DataFeedProcessExecution.getDataFeedPublicationConfigurationIds().

      Parameters:
      targetDataFeedPublicationConfigurationId - feed publication configuration ID that this publication will publish data to
    • setStartTime

      public void setStartTime(@Nullable Instant startTime)
      The time at which this publication started processing.
      Parameters:
      startTime - the time at which this publication started processing
    • setEndTime

      public void setEndTime(@Nullable Instant endTime)
      The time at which this publication stopped processing.
      Parameters:
      endTime - the time at which this publication stopped processing
    • setStatus

      public void setStatus(String status)
      Should contain a value from DefaultDataFeedPublicationStatuses describing the current status of the publication.

      When this is being changed, be sure to update getStartTime() or getEndTime() if appropriate.

      Parameters:
      status - the current status of the publication
    • setContainsErrors

      public void setContainsErrors(boolean containsErrors)
      A simple flag indicating whether the current publication encountered any errors.
      Parameters:
      containsErrors - whether this publication experienced errors
      See Also:
    • setErrorDetails

      public void setErrorDetails(List<String> errorDetails)
      If errors are encountered during the run of this publication (ex: isContainsErrors() is true), details should be added here. Otherwise, this will be empty.
      Parameters:
      errorDetails - details about any errors experienced by this publication
      See Also:
    • setContextState

      public void setContextState(com.broadleafcommerce.data.tracking.core.filtering.business.domain.ContextState contextState)
      A subset of Tracking information to expose the context state for this object.
      Specified by:
      setContextState in interface com.broadleafcommerce.data.tracking.core.ContextStateAware
      Parameters:
      contextState - a subset of Tracking information to expose the context state for this object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • canEqual

      protected boolean canEqual(Object other)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object