Class Batch.BatchBuilder

  • Enclosing class:
    Batch

    public static class Batch.BatchBuilder
    extends Object
    Helper class for building a Batch.
    • Method Detail

      • withBatchAsAmount

        public Batch.BatchBuilder withBatchAsAmount​(int value)
        Sets the batch value representing an exact amount of items
        Parameters:
        value - the exact amount of items, which must be greater than 0
        Returns:
        the Batch
      • withBatchAsPercent

        public Batch.BatchBuilder withBatchAsPercent​(int value)
        Sets the batch value representing a percent
        Parameters:
        value - the percent, which must be greater than 0 and less than or equal to 100
        Returns:
        the Batch
      • withDelay

        public Batch.BatchBuilder withDelay​(Double delayIn)
        Batch delay specifies the time for salt to wait for more minions to return a result before scheduling the next batch. This helps to avoid single minion batches.
        Parameters:
        delayIn - time to wait in seconds.
        Returns:
        this BatchBuilder instance with the specified batch delay.
      • withPresencePingTimeout

        public Batch.BatchBuilder withPresencePingTimeout​(Integer presencePingTimeoutIn)
        Batch presence ping timeout specifies the timeout in seconds of the presence ping performed in salt minions to determine which minions are available during salt batch calls.
        Parameters:
        presencePingTimeoutIn - time to wait in seconds.
        Returns:
        this BatchBuilder instance with the specified batch presence ping timeout.
      • withPresencePingGatherJobTimeout

        public Batch.BatchBuilder withPresencePingGatherJobTimeout​(Integer presencePingGatherJobTimeoutIn)
        Batch presence ping gather job timeout specifies the timeout in seconds for gathering the presence ping jobs performed in salt minions to determine which minions are available during salt batch synchronous calls.
        Parameters:
        presencePingGatherJobTimeoutIn - time to wait in seconds.
        Returns:
        this BatchBuilder instance with the specified batch presence ping gather job timeout.
      • build

        public Batch build()
        Returns a Batch with the values of this BatchBuilder instance.
        Returns:
        a new Batch