Skip to content

Commit 221df62

Browse files
committed
Workaround issue discovered by Stephane after upgrading to Jetty 9.
1 parent 0da1f10 commit 221df62

File tree

3 files changed

+10
-20
lines changed

3 files changed

+10
-20
lines changed

providers/grizzly/src/main/java/org/asynchttpclient/providers/grizzly/statushandler/AuthorizationHandler.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -135,12 +135,13 @@ private Connection getConnectionForNextRequest(final FilterChainContext ctx,
135135
final HttpResponsePacket response,
136136
final HttpTxContext httpCtx)
137137
throws Exception {
138+
/*
138139
if (response.getProcessingState().isKeepAlive()) {
139140
return ctx.getConnection();
140-
} else {
141+
} else { */
141142
final ConnectionManager m = httpCtx.getProvider().getConnectionManager();
142143
return m.obtainConnection(request, httpCtx.getFuture());
143-
}
144+
/* } */
144145
}
145146

146147
} // END AuthorizationHandler

providers/grizzly/src/main/java/org/asynchttpclient/providers/grizzly/statushandler/ProxyAuthorizationHandler.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -224,13 +224,13 @@ private Connection getConnectionForNextRequest(final FilterChainContext ctx,
224224
final HttpResponsePacket response,
225225
final HttpTxContext httpCtx)
226226
throws Exception {
227-
if (response.getProcessingState().isKeepAlive()) {
228-
return ctx.getConnection();
229-
} else {
230-
final ConnectionManager m =
231-
httpCtx.getProvider().getConnectionManager();
232-
return m.obtainConnection(request, httpCtx.getFuture());
233-
}
227+
/*
228+
if (response.getProcessingState().isKeepAlive()) {
229+
return ctx.getConnection();
230+
} else { */
231+
final ConnectionManager m = httpCtx.getProvider().getConnectionManager();
232+
return m.obtainConnection(request, httpCtx.getFuture());
233+
/* } */
234234
}
235235

236236

providers/grizzly/src/test/java/org/asynchttpclient/providers/grizzly/GrizzlyBasicAuthTest.java

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -29,16 +29,5 @@ public AsyncHttpClient getAsyncHttpClient(AsyncHttpClientConfig config) {
2929
public String getProviderClass() {
3030
return GrizzlyAsyncHttpProvider.class.getName();
3131
}
32-
33-
@Test(groups = { "standalone", "default_provider" }, enabled = false)
34-
@Override
35-
public void basicAuthFileTest() throws Exception {
36-
// FIXME
37-
}
3832

39-
@Test(groups = { "standalone", "default_provider" }, enabled = false)
40-
@Override
41-
public void basicAuthFileNoKeepAliveTest() throws Exception {
42-
// FIXME
43-
}
4433
}

0 commit comments

Comments
 (0)