Skip to content

Commit

Permalink
prepare 1.11.3 release (#74)
Browse files Browse the repository at this point in the history
* add time threshold for backoff reset

* allow endpoint to be specified as either URI or HttpUrl

* add @SInCE

* add interface for customizing requests

* javadoc fixes

* add changelog for past releases

* remove JSR305

* replace SSL-specific config method with general-purpose HTTP config method

* make helper method static

* add end-to-end EventSource tests

* spacing

* omit default header value if there's a custom value

* avoid trailing period in logger name

* add 1.x branch

* javadoc fixes

* bump OkHttp version to latest Java 7-compatible version

* add ability to force a stream restart; improve tests so we can test this (#29)

* fix jitter calculation when upper bound is a power of 2

* Fix Java 7 compatibility.

* add OpenJDK 7 build + fix test race condition + javadoc fix (#42)

* use SecureRandom instead of Random, just to make scanners happier

Co-authored-by: Eli Bishop <[email protected]>
Co-authored-by: LaunchDarklyCI <[email protected]>
Co-authored-by: Gavin Whelan <[email protected]>
  • Loading branch information
4 people authored Aug 23, 2022
1 parent 2a3614b commit 71db4dd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/java/com/launchdarkly/eventsource/EventSource.java
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
import java.net.URI;
import java.security.GeneralSecurityException;
import java.security.KeyStore;
import java.security.SecureRandom;
import java.util.Arrays;
import java.util.Locale;
import java.util.Random;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;
import java.util.concurrent.RejectedExecutionException;
Expand Down Expand Up @@ -98,7 +98,7 @@ public class EventSource implements ConnectionHandler, Closeable {
private final AtomicReference<ReadyState> readyState;
private final OkHttpClient client;
private volatile Call call;
private final Random jitter = new Random();
private final SecureRandom jitter = new SecureRandom();
private Response response;
private BufferedSource bufferedSource;

Expand Down

0 comments on commit 71db4dd

Please sign in to comment.