Class ParallelFlowReport

  • All Implemented Interfaces:
    WorkReport

    public class ParallelFlowReport
    extends Object
    implements WorkReport
    Aggregate report of the partial reports of work units executed in a parallel flow.
    Author:
    Mahmoud Ben Hassine (mahmoud.benhassine@icloud.com)
    • Method Detail

      • getReports

        public List<WorkReport> getReports()
        Get partial reports.
        Returns:
        partial reports
      • getStatus

        public WorkStatus getStatus()
        Return the status of the parallel flow. The status of a parallel flow is defined as follows:
        • org.jeasy.flows.work.WorkStatus#COMPLETED: If all work units have successfully completed
        • org.jeasy.flows.work.WorkStatus#FAILED: If one of the work units has failed
        Specified by:
        getStatus in interface WorkReport
        Returns:
        workflow status
      • getError

        public Throwable getError()
        Return the first error of partial reports.
        Specified by:
        getError in interface WorkReport
        Returns:
        the first error of partial reports.
      • getWorkContext

        public WorkContext getWorkContext()
        The parallel flow context is the union of all partial contexts. In a parallel flow, each work unit should have its own unique keys to avoid key overriding when merging partial contexts.
        Specified by:
        getWorkContext in interface WorkReport
        Returns:
        the union of all partial contexts