Class DeploymentJobSchedulingRequestErrorHandler

java.lang.Object
com.broadleafcommerce.sandbox.messaging.completion.error.DeploymentJobSchedulingRequestErrorHandler

public class DeploymentJobSchedulingRequestErrorHandler extends Object
Author:
Chad Harchar (charchar)
  • Constructor Details

  • Method Details

    • recordSchedulingErrors

      public void recordSchedulingErrors(com.broadleafcommerce.data.tracking.core.transition.WorkflowRequestCompletion completion, ChangeDeploy deployment, Collection<ChangeSummaryGroup> changeSummaryGroups)
      Locks the deployment and groups and records the errors encountered while trying to schedule them and updates their statuses to ChangeStatusType.ERROR_SCHEDULE.
      Parameters:
      completion - The WorkflowRequestCompletion which has the errors to record
      deployment - The ChangeDeploy upon which to record errors
      changeSummaryGroups - The ChangeSummaryGroups upon which to record errors
      Throws:
      QualifiedStateException - Thrown if the updates fail.
    • recordSummaryErrors

      protected void recordSummaryErrors(com.broadleafcommerce.data.tracking.core.transition.WorkflowRequestCompletion completion, Collection<ChangeSummaryGroup> groups)
      Records the exception encountered for a failed deployment scheduling onto the ChangeSummary indicated by the WorkflowRequestCompletion and updates its status to ChangeStatusType.ERROR_SCHEDULE.
      Parameters:
      completion - The WorkflowRequestCompletion indicating the group that encountered errors while being scheduled
      groups - Stream of ChangeSummaryGroups from which to derive the IDs of ChangeSummaries.
      Throws:
      QualifiedStateException - Thrown if the summary encounters errors while being updated.
    • recordGroupErrors

      protected void recordGroupErrors(com.broadleafcommerce.data.tracking.core.transition.WorkflowRequestCompletion completion, String groupId)
      Locks and records the exception encountered for a failed deployment scheduling onto the ChangeSummaryGroup indicated by the WorkflowRequestCompletion and updates its status to ChangeStatusType.ERROR_SCHEDULE.
      Parameters:
      completion - The WorkflowRequestCompletion indicating the group that encountered errors while being scheduled
      groupId - the ID of the group upon which to record errors
      Throws:
      QualifiedStateException - Thrown if the group encounters errors while being updated.
    • recordDeploymentErrors

      protected void recordDeploymentErrors(com.broadleafcommerce.data.tracking.core.transition.WorkflowRequestCompletion completion, String deployId)
      Locks and records the exception encountered for a failed deployment scheduling onto the ChangeDeploy indicated by the WorkflowRequestCompletion and updates its status to ChangeStatusType.ERROR_SCHEDULE.
      Parameters:
      completion - The WorkflowRequestCompletion indicating the deployment that encountered errors while being scheduled
      deployId - The ID of the deployment upon which to record errors
      Throws:
      QualifiedStateException - Thrown if the deployment encounters errors while being updated.
    • getSummaryService

      protected ChangeSummaryService<ChangeSummary> getSummaryService()
    • getGroupService

      protected ChangeSummaryGroupService<ChangeSummaryGroup> getGroupService()
    • getChangeDeployService

      protected ChangeDeployService<ChangeDeploy> getChangeDeployService()