public Retryer < R > withWaitStrategy ( WaitStrategy waitStrategy ) { ( this . waitStrategy = ( this . waitStrategy . isPresent ( ) ? this . waitStrategy : Optional . of ( new CompositeWaitStrategy ( ) ) ) ) . get ( ) . put ( checkNotNull ( waitStrategy , "WaitStrategy cannot be null" ) ) ; return this ; }
Sets the wait strategy used to decide how long to sleep between failed attempts . The default strategy is to retry immediately after a failed attempt