Skip to content

Commit

Permalink
added check against null for default predicate
Browse files Browse the repository at this point in the history
  • Loading branch information
YuriyHolinko committed Jan 18, 2025
1 parent 993385f commit d91412b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,7 @@ public static RetryPolicyBuilder builder() {
.setMaxAttempts(DEFAULT_MAX_ATTEMPTS)
.setInitialBackoff(Duration.ofSeconds(DEFAULT_INITIAL_BACKOFF_SECONDS))
.setMaxBackoff(Duration.ofSeconds(DEFAULT_MAX_BACKOFF_SECONDS))
.setBackoffMultiplier(DEFAULT_BACKOFF_MULTIPLIER)
.setRetryExceptionPredicate(null);
.setBackoffMultiplier(DEFAULT_BACKOFF_MULTIPLIER);
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ void build() {
assertThat(retryPolicy.getInitialBackoff()).isEqualTo(Duration.ofMillis(2));
assertThat(retryPolicy.getMaxBackoff()).isEqualTo(Duration.ofSeconds(1));
assertThat(retryPolicy.getBackoffMultiplier()).isEqualTo(1.1);
assertThat(retryPolicy.getRetryExceptionPredicate()).isEqualTo(null);
}

@Test
Expand Down

0 comments on commit d91412b

Please sign in to comment.