Skip to content

Commit

Permalink
feat: support JDK 23 (#2064)
Browse files Browse the repository at this point in the history
* feat: support JDK 23

* format

* fix supported version in ci.yaml
  • Loading branch information
diegomarquezp authored Jan 28, 2025
1 parent 1e70d04 commit b6a3616
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 9 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
strategy:
fail-fast: false
matrix:
java: [8, 11, 17]
java: [8, 11, 17, 23]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
Expand Down Expand Up @@ -54,7 +54,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
java: [8, 11, 17]
java: [8, 11, 17, 23]
steps:
- uses: actions/checkout@v4
- uses: actions/setup-java@v4
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -203,14 +203,17 @@ public void testDisconnectShouldNotWaitToReadResponse() throws IOException {
public void handle(HttpExchange httpExchange) throws IOException {
byte[] response = httpExchange.getRequestURI().toString().getBytes();
httpExchange.sendResponseHeaders(200, response.length);

// Sleep for longer than the test timeout
try {
Thread.sleep(100_000);
} catch (InterruptedException e) {
throw new IOException("interrupted", e);
}
try (OutputStream out = httpExchange.getResponseBody()) {
byte[] firstByte = new byte[] {0x01};
out.write(firstByte);
out.flush();

// Sleep for longer than the test timeout
try {
Thread.sleep(100_000);
} catch (InterruptedException e) {
throw new IOException("interrupted", e);
}
out.write(response);
}
}
Expand Down

0 comments on commit b6a3616

Please sign in to comment.