Search in sources :

Example 16 with OperatedClientConnection

use of org.apache.http.conn.OperatedClientConnection in project platform_external_apache-http by android.

the class AbstractClientConnAdapter method isResponseAvailable.

// non-javadoc, see interface HttpClientConnection
public boolean isResponseAvailable(int timeout) throws IOException {
    assertNotAborted();
    OperatedClientConnection conn = getWrappedConnection();
    assertValid(conn);
    return conn.isResponseAvailable(timeout);
}
Also used : OperatedClientConnection(org.apache.http.conn.OperatedClientConnection)

Example 17 with OperatedClientConnection

use of org.apache.http.conn.OperatedClientConnection in project platform_external_apache-http by android.

the class AbstractClientConnAdapter method getLocalAddress.

// non-javadoc, see interface HttpInetConnection
public InetAddress getLocalAddress() {
    OperatedClientConnection conn = getWrappedConnection();
    assertValid(conn);
    return conn.getLocalAddress();
}
Also used : OperatedClientConnection(org.apache.http.conn.OperatedClientConnection)

Example 18 with OperatedClientConnection

use of org.apache.http.conn.OperatedClientConnection in project jmeter by apache.

the class ManagedClientConnectionImpl method sendRequestHeader.

@Override
public void sendRequestHeader(final HttpRequest request) throws HttpException, IOException {
    final OperatedClientConnection conn = ensureConnection();
    conn.sendRequestHeader(request);
}
Also used : OperatedClientConnection(org.apache.http.conn.OperatedClientConnection)

Example 19 with OperatedClientConnection

use of org.apache.http.conn.OperatedClientConnection in project jmeter by apache.

the class ManagedClientConnectionImpl method shutdown.

@Override
public void shutdown() throws IOException {
    final HttpPoolEntry local = this.poolEntry;
    if (local != null) {
        final OperatedClientConnection conn = local.getConnection();
        local.getTracker().reset();
        conn.shutdown();
    }
}
Also used : OperatedClientConnection(org.apache.http.conn.OperatedClientConnection)

Example 20 with OperatedClientConnection

use of org.apache.http.conn.OperatedClientConnection in project jmeter by apache.

the class ManagedClientConnectionImpl method abortConnection.

@Override
public void abortConnection() {
    synchronized (this) {
        if (this.poolEntry == null) {
            return;
        }
        this.reusable = false;
        final OperatedClientConnection conn = this.poolEntry.getConnection();
        try {
            conn.shutdown();
        } catch (final IOException ignore) {
        // NOSONAR It ok to ignore
        // NOOP
        }
        this.manager.releaseConnection(this, this.duration, TimeUnit.MILLISECONDS);
        this.poolEntry = null;
    }
}
Also used : OperatedClientConnection(org.apache.http.conn.OperatedClientConnection) IOException(java.io.IOException) InterruptedIOException(java.io.InterruptedIOException)

Aggregations

OperatedClientConnection (org.apache.http.conn.OperatedClientConnection)61 InterruptedIOException (java.io.InterruptedIOException)5 IOException (java.io.IOException)4 Socket (java.net.Socket)4 SSLSession (javax.net.ssl.SSLSession)4 SSLSocket (javax.net.ssl.SSLSocket)4 RouteTracker (org.apache.http.conn.routing.RouteTracker)4 ConnectionShutdownException (org.apache.http.impl.conn.ConnectionShutdownException)4 HttpHost (org.apache.http.HttpHost)3