Nitu Choudhary
2018-04-27 18:11:36 UTC
Hi,
I am seeing a deadlock when trying to close the session, please check the stack trace below. The version of nio client we are using is:
      <dependency>
        <groupId>org.apache.httpcomponents</groupId>
        <artifactId>httpcore-nio</artifactId>
        <version>4.4.6</version>
      </dependency>
      <dependency>
        <groupId>org.apache.httpcomponents</groupId>
        <artifactId>httpasyncclient</artifactId>
        <version>4.1.3</version>
      </dependency>
Java stack information for the threads listed above:
===================================================
"Thread-313":
    at java.nio.channels.spi.AbstractSelectionKey.cancel(AbstractSelectionKey.java:70)
    - waiting to lock <0x00002b9628ab9860> (a sun.nio.ch.SelectionKeyImpl)
    at java.nio.channels.spi.AbstractSelectableChannel.implCloseChannel(AbstractSelectableChannel.java:240)
    - locked <0x00002b9628ab9b98> (a java.lang.Object)
    at java.nio.channels.spi.AbstractInterruptibleChannel.close(AbstractInterruptibleChannel.java:115)
    - locked <0x00002b9628ab9808> (a java.lang.Object)
    at org.apache.http.impl.nio.reactor.SessionRequestImpl.cancel(SessionRequestImpl.java:216)
    at org.apache.http.nio.pool.AbstractNIOConnPool.shutdown(AbstractNIOConnPool.java:216)
    at org.apache.http.impl.nio.conn.PoolingNHttpClientConnectionManager.shutdown(PoolingNHttpClientConnectionManager.java:206)
    at org.apache.http.impl.nio.client.CloseableHttpAsyncClientBase.close(CloseableHttpAsyncClientBase.java:99)
    at com.yahoo.ymail.common.http.internal.HttpAsyncClientJmxEnabled.close(HttpAsyncClientJmxEnabled.java:452)
    at com.yahoo.ymail.xmas.common.http.HttpAsyncClientWrapper$1.run(HttpAsyncClientWrapper.java:75)
    at java.lang.Thread.run(Thread.java:748)
"I/O dispatcher 119":
    at java.nio.channels.spi.AbstractInterruptibleChannel.close(AbstractInterruptibleChannel.java:111)
    - waiting to lock <0x00002b9628ab9808> (a java.lang.Object)
    at org.apache.http.impl.nio.reactor.IOSessionImpl.close(IOSessionImpl.java:227)
    - locked <0x00002b9628ab9860> (a sun.nio.ch.SelectionKeyImpl)
    at org.apache.http.impl.nio.reactor.IOSessionImpl.shutdown(IOSessionImpl.java:255)
    at org.apache.http.impl.nio.reactor.AbstractIODispatch.connected(AbstractIODispatch.java:89)
    at org.apache.http.impl.nio.reactor.BaseIOReactor.sessionCreated(BaseIOReactor.java:248)
    at org.apache.http.impl.nio.reactor.AbstractIOReactor.processNewChannels(AbstractIOReactor.java:427)
    at org.apache.http.impl.nio.reactor.AbstractIOReactor.execute(AbstractIOReactor.java:287)
    at org.apache.http.impl.nio.reactor.BaseIOReactor.execute(BaseIOReactor.java:104)
    at org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor$Worker.run(AbstractMultiworkerIOReactor.java:588)
    at java.lang.Thread.run(Thread.java:748)
Regards,nitu
I am seeing a deadlock when trying to close the session, please check the stack trace below. The version of nio client we are using is:
      <dependency>
        <groupId>org.apache.httpcomponents</groupId>
        <artifactId>httpcore-nio</artifactId>
        <version>4.4.6</version>
      </dependency>
      <dependency>
        <groupId>org.apache.httpcomponents</groupId>
        <artifactId>httpasyncclient</artifactId>
        <version>4.1.3</version>
      </dependency>
Java stack information for the threads listed above:
===================================================
"Thread-313":
    at java.nio.channels.spi.AbstractSelectionKey.cancel(AbstractSelectionKey.java:70)
    - waiting to lock <0x00002b9628ab9860> (a sun.nio.ch.SelectionKeyImpl)
    at java.nio.channels.spi.AbstractSelectableChannel.implCloseChannel(AbstractSelectableChannel.java:240)
    - locked <0x00002b9628ab9b98> (a java.lang.Object)
    at java.nio.channels.spi.AbstractInterruptibleChannel.close(AbstractInterruptibleChannel.java:115)
    - locked <0x00002b9628ab9808> (a java.lang.Object)
    at org.apache.http.impl.nio.reactor.SessionRequestImpl.cancel(SessionRequestImpl.java:216)
    at org.apache.http.nio.pool.AbstractNIOConnPool.shutdown(AbstractNIOConnPool.java:216)
    at org.apache.http.impl.nio.conn.PoolingNHttpClientConnectionManager.shutdown(PoolingNHttpClientConnectionManager.java:206)
    at org.apache.http.impl.nio.client.CloseableHttpAsyncClientBase.close(CloseableHttpAsyncClientBase.java:99)
    at com.yahoo.ymail.common.http.internal.HttpAsyncClientJmxEnabled.close(HttpAsyncClientJmxEnabled.java:452)
    at com.yahoo.ymail.xmas.common.http.HttpAsyncClientWrapper$1.run(HttpAsyncClientWrapper.java:75)
    at java.lang.Thread.run(Thread.java:748)
"I/O dispatcher 119":
    at java.nio.channels.spi.AbstractInterruptibleChannel.close(AbstractInterruptibleChannel.java:111)
    - waiting to lock <0x00002b9628ab9808> (a java.lang.Object)
    at org.apache.http.impl.nio.reactor.IOSessionImpl.close(IOSessionImpl.java:227)
    - locked <0x00002b9628ab9860> (a sun.nio.ch.SelectionKeyImpl)
    at org.apache.http.impl.nio.reactor.IOSessionImpl.shutdown(IOSessionImpl.java:255)
    at org.apache.http.impl.nio.reactor.AbstractIODispatch.connected(AbstractIODispatch.java:89)
    at org.apache.http.impl.nio.reactor.BaseIOReactor.sessionCreated(BaseIOReactor.java:248)
    at org.apache.http.impl.nio.reactor.AbstractIOReactor.processNewChannels(AbstractIOReactor.java:427)
    at org.apache.http.impl.nio.reactor.AbstractIOReactor.execute(AbstractIOReactor.java:287)
    at org.apache.http.impl.nio.reactor.BaseIOReactor.execute(BaseIOReactor.java:104)
    at org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor$Worker.run(AbstractMultiworkerIOReactor.java:588)
    at java.lang.Thread.run(Thread.java:748)
Regards,nitu