Class RebasingWorkflowRequestCompletionHandler

java.lang.Object
com.broadleafcommerce.sandbox.messaging.completion.RebasingWorkflowRequestCompletionHandler
All Implemented Interfaces:
WorkflowRequestCompletionHandler

public class RebasingWorkflowRequestCompletionHandler extends Object implements WorkflowRequestCompletionHandler
This handler deals with cleaning up rebased ChangeSummaries' statuses.
  • Constructor Details

  • Method Details

    • canHandle

      public boolean canHandle(@NonNull com.broadleafcommerce.data.tracking.core.transition.WorkflowRequestCompletion completion)
      Description copied from interface: WorkflowRequestCompletionHandler
      Determines if this handler can handle the given WorkflowRequestCompletion. This is typically done by checking the WorkflowRequestCompletion.getRequestType().
      Specified by:
      canHandle in interface WorkflowRequestCompletionHandler
      Parameters:
      completion - a WorkflowRequestCompletion received over the WorkflowRequestCompletionConsumer channel
      Returns:
      whether this handler can handle the given WorkflowRequestCompletion
    • handle

      public void handle(@NonNull com.broadleafcommerce.data.tracking.core.transition.WorkflowRequestCompletion completion)
      Gleans the ID of the ChangeSummary for which a rebasing was requested and updates it as ChangeStatusType.FINISHED if successfully rebased or ChangeStatusType.ERROR_REBASE if it failed, including the error trace.
      Specified by:
      handle in interface WorkflowRequestCompletionHandler
      Parameters:
      completion - a WorkflowRequestCompletion received over the WorkflowRequestCompletionConsumer channel containing information about the rebased ChangeSummary.
    • finishRebasing

      public void finishRebasing(@NonNull com.broadleafcommerce.data.tracking.core.transition.WorkflowRequestCompletion completion, String changeSummaryId)
    • getSummaryService

      protected ChangeSummaryService<ChangeSummary> getSummaryService()
    • getErrorHandler

      protected RebasingWorkflowRequestErrorHandler getErrorHandler()
    • getIndexNotificationService

      protected IndexNotificationService getIndexNotificationService()