@@ -233,10 +233,12 @@ public PoolingHttpClientConnectionManager(
233233 poolReusePolicy ,
234234 disposer ,
235235 null ) {
236+
236237 @ Override
237238 public void closeExpired () {
238239 enumAvailable (e -> closeIfExpired (e ));
239240 }
241+
240242 };
241243 break ;
242244 case LAX :
@@ -246,10 +248,12 @@ public void closeExpired() {
246248 poolReusePolicy ,
247249 disposer ,
248250 null ) {
251+
249252 @ Override
250253 public void closeExpired () {
251254 enumAvailable (e -> closeIfExpired (e ));
252255 }
256+
253257 };
254258 break ;
255259 default :
@@ -289,7 +293,6 @@ public void close(final CloseMode closeMode) {
289293 }
290294 }
291295
292-
293296 private InternalConnectionEndpoint cast (final ConnectionEndpoint endpoint ) {
294297 if (endpoint instanceof InternalConnectionEndpoint ) {
295298 return (InternalConnectionEndpoint ) endpoint ;
@@ -401,7 +404,7 @@ public ConnectionEndpoint get(
401404 } else {
402405 poolEntry .assignConnection (connFactory .createConnection (null ));
403406 }
404- this .endpoint = new InternalConnectionEndpoint (poolEntry , disposer );
407+ this .endpoint = new InternalConnectionEndpoint (poolEntry );
405408 if (LOG .isDebugEnabled ()) {
406409 LOG .debug ("{} acquired {}" , id , ConnPoolSupport .getId (endpoint ));
407410 }
@@ -712,14 +715,11 @@ public void setValidateAfterInactivity(final TimeValue validateAfterInactivity)
712715 static class InternalConnectionEndpoint extends ConnectionEndpoint implements ConnectionHolder , Identifiable {
713716
714717 private final AtomicReference <PoolEntry <HttpRoute , ManagedHttpClientConnection >> poolEntryRef ;
715- private final OffLockDisposalCallback <ManagedHttpClientConnection > disposer ;
716718 private final String id ;
717719
718720 InternalConnectionEndpoint (
719- final PoolEntry <HttpRoute , ManagedHttpClientConnection > poolEntry ,
720- final OffLockDisposalCallback <ManagedHttpClientConnection > disposer ) {
721+ final PoolEntry <HttpRoute , ManagedHttpClientConnection > poolEntry ) {
721722 this .poolEntryRef = new AtomicReference <>(poolEntry );
722- this .disposer = disposer ;
723723 this .id = INCREMENTING_ID .getNextId ();
724724 }
725725
0 commit comments