Skip to content

Commit 04043d8

Browse files
committed
Remove unused code
1 parent afb6d8b commit 04043d8

File tree

1 file changed

+1
-23
lines changed
  • frameworks/Java/inverno/src/main/java/com/techempower/inverno/benchmark/internal

1 file changed

+1
-23
lines changed

frameworks/Java/inverno/src/main/java/com/techempower/inverno/benchmark/internal/Handler.java

Lines changed: 1 addition & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ public void handle(Exchange exchange) throws HttpException {
121121
}
122122
}
123123
}
124-
}
124+
}
125125

126126
private static final byte[] STATIC_PLAINTEXT = "Hello, World!".getBytes(Charsets.UTF_8);
127127
private static final int STATIC_PLAINTEXT_LEN = STATIC_PLAINTEXT.length;
@@ -246,28 +246,6 @@ public void handle_queries(Exchange exchange) throws HttpException {
246246
public void handle_updates(Exchange exchange) throws HttpException {
247247
int queries = this.extractQueriesParameter(exchange);
248248

249-
this.poolSqlClient.get().connection(ops -> Flux.range(0, queries)
250-
.flatMap(ign -> ops.queryForObject(
251-
DB_SELECT_WORLD,
252-
row -> new World(row.getInteger(0), randomWorldId()),
253-
randomWorldId()
254-
)
255-
)
256-
.collectSortedList()
257-
.delayUntil(worlds -> ops.batchUpdate(
258-
DB_UPDATE_WORLD,
259-
worlds.stream().map(world -> new Object[] { world.getRandomNumber(), world.getId() })
260-
)
261-
)
262-
.map(worlds -> {
263-
try {
264-
return Unpooled.unreleasableBuffer(Unpooled.wrappedBuffer(this.mapper.writeValueAsBytes(worlds)));
265-
}
266-
catch (JsonProcessingException e) {
267-
throw new InternalServerErrorException(e);
268-
}
269-
}));
270-
271249
exchange.response()
272250
.headers(h -> h
273251
.add(HttpHeaderNames.SERVER, STATIC_SERVER)

0 commit comments

Comments
 (0)