Skip to content

Commit

Permalink
Fixed a number of errorprone warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
mokies committed May 19, 2018
1 parent 3ff29da commit 1a1b17c
Show file tree
Hide file tree
Showing 10 changed files with 10 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,7 @@ protected Factory<RequestRateLimiterFactory> createValueFactory(final Parameter
return null;
} else {
return new AbstractContainerRequestValueFactory<RequestRateLimiterFactory>() {
@Override
public RequestRateLimiterFactory provide() {
return requestRateLimiterFactory;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ public class RateLimitApplication extends Application<Configuration> {

private RedisClient redisClient;

@Override
public void initialize(Bootstrap<Configuration> bootstrap) {
redisClient = RedisClient.create("redis://localhost");
RequestRateLimiterFactory factory = new RedisRateLimiterFactory(redisClient);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ protected Factory<?> createValueFactory(final Parameter parameter) {
return null;
} else {
return new AbstractContainerRequestValueFactory<RequestRateLimiterFactory>() {
@Override
public RequestRateLimiterFactory provide() {
return requestRateLimiterFactory;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ public boolean hasAcquired() {
return acquired;
}

@Override
public <T> Optional<T> get(Supplier<T> action) {
if (!acquired) {
return Optional.empty();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ static void beforeAll() {
}

@AfterAll
@SuppressWarnings("FutureReturnValueIgnored")
static void afterAll() {
client.shutdownAsync();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ static void beforeAll() {
}

@AfterAll
@SuppressWarnings("FutureReturnValueIgnored")
static void afterAll() {
client.shutdownAsync();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ static void beforeAll() {
}

@AfterAll
@SuppressWarnings("FutureReturnValueIgnored")
static void afterAll() {
client.shutdownAsync();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ static void beforeAll() {
}

@AfterAll
@SuppressWarnings("FutureReturnValueIgnored")
static void afterAll() {
client.shutdownAsync();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ static void beforeAll() {
}

@AfterAll
@SuppressWarnings("FutureReturnValueIgnored")
static void afterAll() {
client.shutdownAsync();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ static void beforeAll() {
}

@AfterAll
@SuppressWarnings("FutureReturnValueIgnored")
static void afterAll() {
client.shutdownAsync();
}
Expand Down

0 comments on commit 1a1b17c

Please sign in to comment.