Class FlatBatchUtil


  • public final class FlatBatchUtil
    extends Object
    Provides flat batch util methods.
    • Method Detail

      • markBarriersWhereNeeded

        public static void markBarriersWhereNeeded​(List<BatchPlanStep> batchPlan)
      • mergeJobsResultsFutures

        public static com.google.common.util.concurrent.ListenableFuture<org.opendaylight.yangtools.yang.common.RpcResult<ProcessFlatBatchOutput>> mergeJobsResultsFutures​(List<com.google.common.util.concurrent.ListenableFuture<org.opendaylight.yangtools.yang.common.RpcResult<ProcessFlatBatchOutput>>> firedJobs)
        Merge list of Futures with partial results into one ListenableFuture with single result.
        Parameters:
        firedJobs - list of ListenableFutures with RPC results ProcessFlatBatchOutput
        Returns:
        ListenableFuture of RPC result with combined status and all errors + batch failures
      • createEmptyRpcBatchResultFuture

        public static com.google.common.util.concurrent.ListenableFuture<org.opendaylight.yangtools.yang.common.RpcResult<ProcessFlatBatchOutput>> createEmptyRpcBatchResultFuture​(boolean status)
        Creates empty result future for flat batch service.
        Parameters:
        status - RPC result status
        Returns:
        ListenableFuture of RPC result with empty list of errors and batch failures