Class ApacheConnectionClosingStrategy.GracefulClosingStrategy
java.lang.Object
org.glassfish.jersey.apache.connector.ApacheConnectionClosingStrategy.GracefulClosingStrategy
- All Implemented Interfaces:
ApacheConnectionClosingStrategy
- Enclosing interface:
- ApacheConnectionClosingStrategy
public static class ApacheConnectionClosingStrategy.GracefulClosingStrategy
extends Object
implements ApacheConnectionClosingStrategy
Strategy that aborts Apache HttpRequests for the case of Chunked Stream, closes the stream, and response next.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.glassfish.jersey.apache.connector.ApacheConnectionClosingStrategy
ApacheConnectionClosingStrategy.GracefulClosingStrategy, ApacheConnectionClosingStrategy.ImmediateClosingStrategy
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close
(ClientRequest clientRequest, org.apache.http.client.methods.HttpUriRequest request, org.apache.http.client.methods.CloseableHttpResponse response, InputStream stream) Method to close the connection.
-
Constructor Details
-
GracefulClosingStrategy
public GracefulClosingStrategy()
-
-
Method Details
-
close
public void close(ClientRequest clientRequest, org.apache.http.client.methods.HttpUriRequest request, org.apache.http.client.methods.CloseableHttpResponse response, InputStream stream) throws IOException Description copied from interface:ApacheConnectionClosingStrategy
Method to close the connection.- Specified by:
close
in interfaceApacheConnectionClosingStrategy
- Parameters:
clientRequest
- TheClientRequest
to getconfiguration
, andresolve properties
.request
- ApacheHttpUriRequest
that can beabort
ed.response
- ApacheCloseableHttpResponse
that can beclose
d.stream
- The entity stream that can beclosed
.- Throws:
IOException
- In case of some of the closing methods throwsIOException
-