Skip to content

Commit 357ef9b

Browse files
committed
Passes the build
1 parent a4c9e68 commit 357ef9b

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

okhttp-clients/src/main/java/com/palantir/remoting3/okhttp/RemotingConcurrencyLimiter.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@ private void updateWindow(long endTime, Predicate<ImmutableSampleWindow> shouldF
156156
}
157157
}
158158

159-
private boolean isWindowReady(ImmutableSampleWindow sample) {
160-
return sample.getCandidateRttNanos() < Long.MAX_VALUE && sample.getSampleCount() > windowSize;
159+
private boolean isWindowReady(ImmutableSampleWindow window) {
160+
return window.getCandidateRttNanos() < Long.MAX_VALUE && window.getSampleCount() > windowSize;
161161
}
162162
}

okhttp-clients/src/test/java/com/palantir/remoting3/okhttp/ConcurrencyLimitersTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,4 +56,4 @@ public void testFifo() throws ExecutionException, InterruptedException {
5656
first.get().onIgnore();
5757
assertThat(second.isDone()).isTrue();
5858
}
59-
}
59+
}

okhttp-clients/src/test/java/com/palantir/remoting3/okhttp/FlowControlTest.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,12 +51,12 @@
5151
* to try different strategies.
5252
* <p>
5353
* It is run in CI, but only to prevent code breakages - this is in general an expensive test which should be run
54-
* as a dev tool.
54+
* as a dev tool. If you want to run for dev purposes, please increase REQUESTS_PER_THREAD.
5555
*/
5656
public final class FlowControlTest {
5757
private static final Logger log = LoggerFactory.getLogger(FlowControlTest.class);
5858
private static final Duration GRACE = Duration.ofMinutes(2);
59-
private static final int REQUESTS_PER_THREAD = System.getenv("CI") == null ? 1000 : 1;
59+
private static final int REQUESTS_PER_THREAD = 5;
6060
private static final ConcurrencyLimiters limiters = new ConcurrencyLimiters();
6161
private static ListeningExecutorService executorService;
6262

@@ -107,7 +107,7 @@ private Stream<Worker> createWorkers(
107107
avgRetries));
108108
}
109109

110-
private static class Worker implements Runnable {
110+
private static final class Worker implements Runnable {
111111
private final Supplier<BackoffStrategy> backoffFactory;
112112
private final ConcurrencyLimiter limiter;
113113
private final Duration successDuration;

0 commit comments

Comments
 (0)