Class HedgingPolicy


  • @Immutable
    final class HedgingPolicy
    extends java.lang.Object
    Hedging policy data object.
    • Constructor Summary

      Constructors 
      Constructor Description
      HedgingPolicy​(int maxAttempts, long hedgingDelayNanos, java.util.Set<Status.Code> nonFatalStatusCodes)
      The caller is supposed to have validated the arguments and handled throwing exception or logging warnings already, so we avoid repeating args check here.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object other)  
      int hashCode()  
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
    • Field Detail

      • maxAttempts

        final int maxAttempts
      • hedgingDelayNanos

        final long hedgingDelayNanos
      • nonFatalStatusCodes

        final java.util.Set<Status.Code> nonFatalStatusCodes
    • Constructor Detail

      • HedgingPolicy

        HedgingPolicy​(int maxAttempts,
                      long hedgingDelayNanos,
                      java.util.Set<Status.Code> nonFatalStatusCodes)
        The caller is supposed to have validated the arguments and handled throwing exception or logging warnings already, so we avoid repeating args check here.
    • Method Detail

      • equals

        public boolean equals​(java.lang.Object other)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object