Atmosphere / wasync

WebSockets with fallback transports client library for Node.js, Android and Java
http://async-io.org
161 stars 47 forks source link

FD for the Atmosphere socket not released after closing the socket #102

Closed schandr closed 9 years ago

schandr commented 10 years ago

This is related to the post in the Atmosphere googlegroups forum https://groups.google.com/forum/#!topic/atmosphere-framework/Ls1K9CmXSho

I tried attaching the test case by posting a reply, but the post gets disappeared. The attached file has the testcase which I packaged as a jar file with dependencies (wasync1.4.0, asynchttpclient 1.8.11). When I run the TestClient(main class) within the jar, i can see the FD for the socket by running lsof -p PID even after the closing the socket connection. I am using tomcat 7.0.51 for the webserver

public class TestClient {
    private Socket socketHandle;
    private AsyncHttpClient asyncClient;
    public void connect() {
        final AtmosphereClient client = ClientFactory.getDefault().newClient(
                AtmosphereClient.class);
        RequestBuilder request = getRequestBuilder(client);
        DefaultOptionsBuilder builder = client.newOptionsBuilder();
        builder.binary(true);
        DefaultOptions options = builder.build();
        this.socketHandle = client.create(options);
        asyncClient = options.runtime();

        socketHandle.on(Event.MESSAGE.name(), new Function<byte[]>() {
            @Override
            public void on(byte[] t) {
            }
        }).on(new Function<Throwable>() {
            @Override
            public void on(Throwable t) {
            }
        }).on(Event.CLOSE.name(), new Function<String>() {
            @Override
            public void on(String t) {
                System.out.println("Connection closed");
            }
        });
        try {
            socketHandle.open(request.build());
        } catch (IOException ioe) {
            this.shutdown();
        }
    }

    private RequestBuilder getRequestBuilder(final AtmosphereClient client) {

        RequestBuilder requestBuilder = client.newRequestBuilder()
                .method(Request.METHOD.GET)
                .uri("http://localhost:8080/test/service")
                .transport(Request.TRANSPORT.WEBSOCKET);
        requestBuilder.queryString("X-Atmosphere-Binary", "true");
        return requestBuilder;
    }

    public void shutdown() {
        if (this.socketHandle != null) {
            if (asyncClient != null)
                asyncClient.closeAsynchronously();
            socketHandle.close();
            socketHandle = null;
        }
    }
}

VM spec

Linux localhost.localdomain 2.6.32-431.el6.x86_64 #1 SMP Sun Nov 10 22:19:54 EST 2013 x86_64 x86_64 x86_64 GNU/Linux

App server - Tomcat 7.0.51

When I did the lsof PID, I am seeing the socket FD as shown below java 10611 root 38u unix 0xffff88013bcdb3c0 0t0 163110 socket

jfarcand commented 10 years ago

AHC is shared, hence not closed. Please test using .runtimeShared(false)

        Socket socket = client.create(client.newOptionsBuilder().runtime(ahc).runtimeShared(false).build());
schandr commented 10 years ago

I modified the code to set the runtimeShared(false)

        builder.runtimeShared(false);
        builder.binary(true);
        DefaultOptions options = builder.build();
        this.socketHandle = client.create(options);
        asyncClient = options.runtime();

Still seeing the same behavior. I can see the socket FD after closing the socket.

java 20542 root 38u unix 0xffff88013c3a6080 0t0 210817 socket

Also trying the below code, results in a 302 error, for which you have asked me to get the network traffice details by using wireshark in the google forum(https://groups.google.com/forum/#!topic/atmosphere-framework/6tbplljRvMA).

Since I got the 302 code with creating a new instance of asyncClient, I retrieved the asyncClient instance from the options.runtime(), since the Client.create method creates a new instance everytime.

final AsyncHttpClient asyncClient = new AsyncHttpClient(new AsyncHttpClientConfig.Builder().setMaxRequestRetry(0).build()); Socket socket = client.create(client.newOptionsBuilder().runtime(ahc).runtimeShared(false).build());

Wireshark details for the 302 code 0000 00 0c 29 13 20 c8 d4 be d9 3b 63 cc 08 00 45 00 ..). ... .;c...E. 0010 02 5b 13 03 40 00 80 06 cd 36 0a c0 01 6c 0a c0 .[..@... .6...l.. 0020 01 78 f4 a4 00 50 82 54 25 04 74 29 b7 e0 50 18 .x...P.T %.t)..P. 0030 01 00 91 d5 00 00 47 45 54 20 2f 64 6d 69 70 2d ......GE T /app/test 0040 67 77 2f 63 6f 6e 73 75 6d 65 2f 74 6f 70 69 63 /service 0050 3f 41 50 50 4c 49 43 41 54 49 4f 4e 5f 4e 41 4d ?APPLICA TIONNAM 0060 45 3d 53 79 73 74 65 6d 25 32 30 44 61 73 68 62 E=System %20Dashb 0070 6f 61 72 64 26 58 2d 41 74 6d 6f 73 70 68 65 72 oard&X-A tmospher 0080 65 2d 54 72 61 6e 73 70 6f 72 74 3d 77 65 62 73 e-Transp ort=webs 0090 6f 63 6b 65 74 26 58 2d 41 74 6d 6f 73 70 68 65 ocket&X- Atmosphe 00a0 72 65 2d 46 72 61 6d 65 77 6f 72 6b 3d 32 2e 32 re-Frame work=2.2 00b0 2e 31 26 44 4d 49 50 5f 53 45 52 56 49 43 45 53 .1&DMIP SERVICES 00c0 5f 55 52 4c 3d 68 74 74 70 25 33 41 25 32 46 25 _URL=htt p%3A%2F% 00d0 32 46 31 30 2e 31 39 32 2e 31 2e 31 32 30 25 32 2F10.192 .1.120%2 00e0 46 64 6d 69 70 2d 67 77 25 32 46 26 54 4f 50 49 Fapp %2F&TOPI 00f0 43 5f 4e 41 4d 45 3d 64 65 62 75 67 4a 42 26 58 C_NAME=d ebugJB&X 0100 2d 61 74 6d 6f 2d 70 72 6f 74 6f 63 6f 6c 3d 74 -atmo-pr otocol=t 0110 72 75 65 26 58 2d 41 74 6d 6f 73 70 68 65 72 65 rue&X-At mosphere 0120 2d 74 72 61 63 6b 69 6e 67 2d 69 64 3d 30 26 54 -trackin g-id=0&T 0130 45 4e 41 4e 54 5f 49 44 3d 31 26 58 2d 43 61 63 ENANT_ID =1&X-Cac 0140 68 65 2d 44 61 74 65 3d 30 26 58 2d 41 74 6d 6f he-Date= 0&X-Atmo 0150 73 70 68 65 72 65 2d 42 69 6e 61 72 79 3d 74 72 sphere-B inary=tr 0160 75 65 20 48 54 54 50 2f 31 2e 31 0d 0a 55 70 67 ue HTTP/ 1.1..Upg 0170 72 61 64 65 3a 20 57 65 62 53 6f 63 6b 65 74 0d rade: We bSocket. 0180 0a 43 6f 6e 6e 65 63 74 69 6f 6e 3a 20 55 70 67 .Connect ion: Upg 0190 72 61 64 65 0d 0a 4f 72 69 67 69 6e 3a 20 68 74 rade..Or igin: ht 01a0 74 70 3a 2f 2f 31 30 2e 31 39 32 2e 31 2e 31 32 tp://10. 192.1.12 01b0 30 3a 2d 31 0d 0a 53 65 63 2d 57 65 62 53 6f 63 0:-1..Se c-WebSoc 01c0 6b 65 74 2d 4b 65 79 3a 20 51 42 74 76 55 44 6b ket-Key: QBtvUDk 01d0 38 45 6b 57 55 43 44 69 47 4e 46 77 58 6c 41 3d 8EkWUCDi GNFwXlA= 01e0 3d 0d 0a 53 65 63 2d 57 65 62 53 6f 63 6b 65 74 =..Sec-W ebSocket 01f0 2d 56 65 72 73 69 6f 6e 3a 20 31 33 0d 0a 48 6f -Version : 13..Ho 0200 73 74 3a 20 31 30 2e 31 39 32 2e 31 2e 31 32 30 st: 10.1 92.1.120 0210 0d 0a 44 4d 49 50 5f 54 4f 4b 45 4e 3a 20 33 65 ..DMIPT OKEN: 3e 0220 63 64 61 32 35 31 2d 62 64 62 65 2d 34 64 31 61 cda251-b dbe-4d1a 0230 2d 61 30 31 36 2d 66 38 31 38 32 39 31 32 66 61 -a016-f8 182912fa 0240 37 65 0d 0a 41 63 63 65 70 74 3a 20 2a 2f 2a 0d 7e..Acce pt: /_. 0250 0a 55 73 65 72 2d 41 67 65 6e 74 3a 20 4e 49 4e .User-Ag ent: NIN 0260 47 2f 31 2e 30 0d 0a 0d 0a G/1.0... .

jfarcand commented 10 years ago

So closing ahc.close and you still see the FD? Can you paste the lsof so I can see the state of the socket.

schandr commented 10 years ago

[root@localhost ~]# lsof -p 20542 COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME java 20542 root cwd DIR 253,4 4096 262240 /apps/test java 20542 root rtd DIR 253,0 4096 2 / java 20542 root txt REG 253,0 7718 408705 /usr/java/jdk1.7.0_51/bin/java java 20542 root mem REG 253,0 156928 172610 /lib64/ld-2.12.so java 20542 root mem REG 253,0 599384 172977 /lib64/libm-2.12.so java 20542 root mem REG 253,0 1926800 172621 /lib64/libc-2.12.so java 20542 root mem REG 253,0 22536 172637 /lib64/libdl-2.12.so java 20542 root mem REG 253,0 145896 172622 /lib64/libpthread-2.12.so java 20542 root mem REG 253,0 47064 172624 /lib64/librt-2.12.so java 20542 root mem REG 253,0 68864 145815 /lib64/libnss_files-2.12.so java 20542 root mem REG 253,0 93320 164633 /lib64/libgcc_s-4.4.7-20120601.so.1 java 20542 root mem REG 253,0 99158576 451493 /usr/lib/locale/locale-archive java 20542 root mem REG 253,0 256462 419142 /usr/java/jdk1.7.0_51/jre/lib/amd64/libsunec.so java 20542 root mem REG 253,0 91178 418552 /usr/java/jdk1.7.0_51/jre/lib/amd64/libnio.so java 20542 root mem REG 253,0 114742 418359 /usr/java/jdk1.7.0_51/jre/lib/amd64/libnet.so java 20542 root mem REG 253,4 4925649 262257 /apps/test/dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar java 20542 root mem REG 253,0 62371704 458191 /usr/java/jdk1.7.0_51/jre/lib/rt.jar java 20542 root mem REG 253,0 196265 441430 /usr/java/jdk1.7.0_51/jre/lib/ext/sunjce_provider.jar java 20542 root mem REG 253,0 15861 441316 /usr/java/jdk1.7.0_51/jre/lib/ext/sunec.jar java 20542 root mem REG 253,0 108463 446064 /usr/java/jdk1.7.0_51/jre/lib/jce.jar java 20542 root mem REG 253,0 580558 446135 /usr/java/jdk1.7.0_51/jre/lib/jsse.jar java 20542 root mem REG 253,0 123434 419654 /usr/java/jdk1.7.0_51/jre/lib/amd64/libzip.so java 20542 root mem REG 253,0 219639 411432 /usr/java/jdk1.7.0_51/jre/lib/amd64/libjava.so java 20542 root mem REG 253,0 65437 419650 /usr/java/jdk1.7.0_51/jre/lib/amd64/libverify.so java 20542 root mem REG 253,0 15141776 419894 /usr/java/jdk1.7.0_51/jre/lib/amd64/server/libjvm.so java 20542 root mem REG 253,0 106366 451985 /usr/java/jdk1.7.0_51/lib/amd64/jli/libjli.so java 20542 root mem REG 253,0 761111 446134 /usr/java/jdk1.7.0_51/jre/lib/resources.jar java 20542 root mem REG 253,2 32768 144 /tmp/hsperfdata_root/20542 java 20542 root 0u CHR 136,2 0t0 5 /dev/pts/2 java 20542 root 1u CHR 136,2 0t0 5 /dev/pts/2 java 20542 root 2u CHR 136,2 0t0 5 /dev/pts/2 java 20542 root 3r REG 253,0 62371704 458191 /usr/java/jdk1.7.0_51/jre/lib/rt.jar java 20542 root 4r REG 253,4 4925649 262257 /apps/test/dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar java 20542 root 5r REG 253,0 761111 446134 /usr/java/jdk1.7.0_51/jre/lib/resources.jar java 20542 root 6w REG 253,4 167913 262252 /apps/test/dmipclient.log java 20542 root 7r REG 253,0 580558 446135 /usr/java/jdk1.7.0_51/jre/lib/jsse.jar java 20542 root 8r CHR 1,8 0t0 3804 /dev/random java 20542 root 9r CHR 1,9 0t0 3805 /dev/urandom java 20542 root 38u unix 0xffff88013c3a6080 0t0 210817 socket java 20542 root 39r REG 253,0 108463 446064 /usr/java/jdk1.7.0_51/jre/lib/jce.jar java 20542 root 40r REG 253,0 15861 441316 /usr/java/jdk1.7.0_51/jre/lib/ext/sunec.jar java 20542 root 41r REG 253,0 196265 441430 /usr/java/jdk1.7.0_51/jre/lib/ext/sunjce_provider.jar

jfarcand commented 10 years ago

Do netstat -as | grep 8080

schandr commented 10 years ago

[root@localhost ~]# netstat -as |grep 80 InOctets: 1073807689 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 InOctets: 1090398042 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 1488066 packets header predicted [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80 [root@localhost ~]# netstat -as |grep 80

jfarcand commented 10 years ago

OK so seems to be fine, no?

schandr commented 10 years ago

Netstat result when 302 is received.

803 segments retransmited
803 segments retransmited
803 segments retransmited
803 segments retransmited
803 segments retransmited
InBcastOctets: 5076806

No, please see the log below, i am getting TransportNotsupported exception when I use the below code

final AtmosphereClient client = ClientFactory.getDefault().newClient(AtmosphereClient.class); final AsyncHttpClient asyncClient = new AsyncHttpClient(new AsyncHttpClientConfig.Builder().setMaxRequestRetry(0).build());

    RequestBuilder request = getRequestBuilder(client);
    DefaultOptionsBuilder builder = client.newOptionsBuilder();
    builder.binary(true);
    builder.runtime(asyncClient);
    builder.runtimeShared(false);
    DefaultOptions options = builder.build();
    final Socket socketHandle = client.create(options);

13:40:44.223 [pool-2-thread-1] DEBUG c.n.h.c.p.n.NettyAsyncHttpProvider - Non cached request DefaultHttpRequest(chunked: false) GET /dmip-gw/consume/topic?APPLICATION_NAME=System%20Dashboard&X-Atmosphere-Transport=websocket&X-Atmosphere-Framework=2.2.1&DMIP_SERVICES_URL=http%3A%2F%2F10.192.1.120%2Fdmip-gw%2F&TOPIC_NAME=job16&X-atmo-protocol=true&X-Atmosphere-tracking-id=0&TENANT_ID=1&X-Cache-Date=0&X-Atmosphere-Binary=true HTTP/1.1 Upgrade: WebSocket Connection: Upgrade Origin: http://10.192.1.120:-1 Sec-WebSocket-Key: OdyfwiuUeV9wrvgXdTWr6g== Sec-WebSocket-Version: 13 Host: 10.192.1.120 DMIPTOKEN: 3ecda251-bdbe-4d1a-a016-f8182912fa7e Accept: /_ User-Agent: NING/1.0

using Channel [id: 0x37b90e4a, /10.192.1.120:58603 :> /10.192.1.120:80]

13:40:44.242 [New I/O worker #1] DEBUG o.a.w.transport.WebSocketTransport - Invalid status code 302 for WebSocket Handshake 13:40:44.248 [New I/O worker #1] DEBUG c.n.h.c.p.n.NettyAsyncHttpProvider - Unexpected I/O exception on channel [id: 0x37b90e4a, /10.192.1.120:58603 => /10.192.1.120:80] org.atmosphere.wasync.transport.TransportNotSupported: null at org.atmosphere.wasync.transport.WebSocketTransport.onStatusReceived(WebSocketTransport.java:199) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider$WebSocketProtocol.handle(NettyAsyncHttpProvider.java:2340) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider.messageReceived(NettyAsyncHttpProvider.java:1228) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:296) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.frame.FrameDecoder.unfoldAndFireMessageReceived(FrameDecoder.java:459) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.callDecode(ReplayingDecoder.java:536) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.messageReceived(ReplayingDecoder.java:435) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.http.HttpClientCodec.handleUpstream(HttpClientCodec.java:92) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:268) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:255) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:88) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.process(AbstractNioWorker.java:108) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioSelector.run(AbstractNioSelector.java:318) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.run(AbstractNioWorker.java:89) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:178) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_51] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [na:1.7.0_51] at java.lang.Thread.run(Thread.java:744) [na:1.7.0_51] 13:40:44.249 [New I/O worker #1] DEBUG c.n.h.c.p.n.NettyAsyncHttpProvider - Was unable to recover Future: NettyResponseFuture{currentRetry=0, isDone=false, isCancelled=false, asyncHandler=org.atmosphere.wasync.transport.WebSocketTransport@45e59c14, requestTimeoutInMs=60000, nettyRequest=DefaultHttpRequest(chunked: false) GET /dmip-gw/consume/topic?APPLICATION_NAME=System%20Dashboard&X-Atmosphere-Transport=websocket&X-Atmosphere-Framework=2.2.1&DMIP_SERVICES_URL=http%3A%2F%2F10.192.1.120%2Fdmip-gw%2F&TOPIC_NAME=job16&X-atmo-protocol=true&X-Atmosphere-tracking-id=0&TENANT_ID=1&X-Cache-Date=0&X-Atmosphere-Binary=true HTTP/1.1 Upgrade: WebSocket Connection: Upgrade Origin: http://10.192.1.120:-1 Sec-WebSocket-Key: OdyfwiuUeV9wrvgXdTWr6g== Sec-WebSocket-Version: 13 Host: 10.192.1.120 DMIPTOKEN: 3ecda251-bdbe-4d1a-a016-f8182912fa7e Accept: /_ User-Agent: NING/1.0, content=null, uri=ws://10.192.1.120/dmip-gw/consume/topic?APPLICATION_NAME=System%20Dashboard&X-Atmosphere-Transport=websocket&X-Atmosphere-Framework=2.2.1&DMIP_SERVICES_URL=http%3A%2F%2F10.192.1.120%2Fdmip-gw%2F&TOPIC_NAME=job16&X-atmo-protocol=true&X-Atmosphere-tracking-id=0&TENANT_ID=1&X-Cache-Date=0&X-Atmosphere-Binary=true, keepAlive=true, httpResponse=DefaultHttpResponse(chunked: false) HTTP/1.1 302 Found Server: Apache-Coyote/1.1 Cache-Control: private Expires: Wed, 31 Dec 1969 18:00:00 CST Location: https://10.192.1.120/dmip-gw/consume/topic?APPLICATION_NAME=System%20Dashboard&X-Atmosphere-Transport=websocket&X-Atmosphere-Framework=2.2.1&DMIP_SERVICES_URL=http%3A%2F%2F10.192.1.120%2Fdmip-gw%2F&TOPIC_NAME=job16&X-atmo-protocol=true&X-Atmosphere-tracking-id=0&TENANT_ID=1&X-Cache-Date=0&X-Atmosphere-Binary=true Content-Length: 0 Date: Thu, 09 Oct 2014 18:40:44 GMT, exEx=null, redirectCount=0, timeoutsHolder=com.ning.http.client.providers.netty.timeout.TimeoutsHolder@656a08e5, inAuth=false, statusReceived=false, touch=15392094} 13:40:44.249 [New I/O worker #1] DEBUG c.n.h.c.p.n.NettyAsyncHttpProvider - Aborting Future NettyResponseFuture{currentRetry=0, isDone=false, isCancelled=false, asyncHandler=org.atmosphere.wasync.transport.WebSocketTransport@45e59c14, requestTimeoutInMs=60000, nettyRequest=DefaultHttpRequest(chunked: false) GET /dmip-gw/consume/topic?APPLICATION_NAME=System%20Dashboard&X-Atmosphere-Transport=websocket&X-Atmosphere-Framework=2.2.1&DMIP_SERVICES_URL=http%3A%2F%2F10.192.1.120%2Fdmip-gw%2F&TOPIC_NAME=job16&X-atmo-protocol=true&X-Atmosphere-tracking-id=0&TENANT_ID=1&X-Cache-Date=0&X-Atmosphere-Binary=true HTTP/1.1 Upgrade: WebSocket Connection: Upgrade Origin: http://10.192.1.120:-1 Sec-WebSocket-Key: OdyfwiuUeV9wrvgXdTWr6g== Sec-WebSocket-Version: 13 Host: 10.192.1.120 DMIPTOKEN: 3ecda251-bdbe-4d1a-a016-f8182912fa7e Accept: /_ User-Agent: NING/1.0, content=null, uri=ws://10.192.1.120/dmip-gw/consume/topic?APPLICATION_NAME=System%20Dashboard&X-Atmosphere-Transport=websocket&X-Atmosphere-Framework=2.2.1&DMIP_SERVICES_URL=http%3A%2F%2F10.192.1.120%2Fdmip-gw%2F&TOPIC_NAME=job16&X-atmo-protocol=true&X-Atmosphere-tracking-id=0&TENANT_ID=1&X-Cache-Date=0&X-Atmosphere-Binary=true, keepAlive=true, httpResponse=DefaultHttpResponse(chunked: false) HTTP/1.1 302 Found Server: Apache-Coyote/1.1 Cache-Control: private Expires: Wed, 31 Dec 1969 18:00:00 CST Location: https://10.192.1.120/dmip-gw/consume/topic?APPLICATION_NAME=System%20Dashboard&X-Atmosphere-Transport=websocket&X-Atmosphere-Framework=2.2.1&DMIP_SERVICES_URL=http%3A%2F%2F10.192.1.120%2Fdmip-gw%2F&TOPIC_NAME=job16&X-atmo-protocol=true&X-Atmosphere-tracking-id=0&TENANT_ID=1&X-Cache-Date=0&X-Atmosphere-Binary=true Content-Length: 0 Date: Thu, 09 Oct 2014 18:40:44 GMT, exEx=null, redirectCount=0, timeoutsHolder=com.ning.http.client.providers.netty.timeout.TimeoutsHolder@656a08e5, inAuth=false, statusReceived=false, touch=15392094}

13:40:44.250 [New I/O worker #1] DEBUG c.n.h.c.p.n.NettyAsyncHttpProvider - null org.atmosphere.wasync.transport.TransportNotSupported: null at org.atmosphere.wasync.transport.WebSocketTransport.onStatusReceived(WebSocketTransport.java:199) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider$WebSocketProtocol.handle(NettyAsyncHttpProvider.java:2340) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider.messageReceived(NettyAsyncHttpProvider.java:1228) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:296) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.frame.FrameDecoder.unfoldAndFireMessageReceived(FrameDecoder.java:459) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.callDecode(ReplayingDecoder.java:536) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.messageReceived(ReplayingDecoder.java:435) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.http.HttpClientCodec.handleUpstream(HttpClientCodec.java:92) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:268) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:255) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:88) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.process(AbstractNioWorker.java:108) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioSelector.run(AbstractNioSelector.java:318) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.run(AbstractNioWorker.java:89) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:178) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_51] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [na:1.7.0_51] at java.lang.Thread.run(Thread.java:744) [na:1.7.0_51] 13:40:44.251 [New I/O worker #1] DEBUG o.a.w.transport.WebSocketTransport - org.atmosphere.wasync.transport.TransportNotSupported: null at org.atmosphere.wasync.transport.WebSocketTransport.onStatusReceived(WebSocketTransport.java:199) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider$WebSocketProtocol.handle(NettyAsyncHttpProvider.java:2340) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider.messageReceived(NettyAsyncHttpProvider.java:1228) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:296) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.frame.FrameDecoder.unfoldAndFireMessageReceived(FrameDecoder.java:459) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.callDecode(ReplayingDecoder.java:536) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.messageReceived(ReplayingDecoder.java:435) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.http.HttpClientCodec.handleUpstream(HttpClientCodec.java:92) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:268) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:255) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:88) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.process(AbstractNioWorker.java:108) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioSelector.run(AbstractNioSelector.java:318) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.run(AbstractNioWorker.java:89) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:178) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_51] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [na:1.7.0_51] at java.lang.Thread.run(Thread.java:744) [na:1.7.0_51] 13:40:44.253 [New I/O worker #1] ERROR c.f.d.a.AbstractDmipClient - Exception reading data: {} org.atmosphere.wasync.transport.TransportNotSupported: null at org.atmosphere.wasync.transport.WebSocketTransport.onStatusReceived(WebSocketTransport.java:199) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider$WebSocketProtocol.handle(NettyAsyncHttpProvider.java:2340) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider.messageReceived(NettyAsyncHttpProvider.java:1228) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:296) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.frame.FrameDecoder.unfoldAndFireMessageReceived(FrameDecoder.java:459) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.callDecode(ReplayingDecoder.java:536) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.messageReceived(ReplayingDecoder.java:435) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.http.HttpClientCodec.handleUpstream(HttpClientCodec.java:92) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:268) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:255) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:88) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.process(AbstractNioWorker.java:108) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioSelector.run(AbstractNioSelector.java:318) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.run(AbstractNioWorker.java:89) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:178) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_51] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [na:1.7.0_51] at java.lang.Thread.run(Thread.java:744) [na:1.7.0_51] 13:40:44.255 [New I/O worker #1] INFO c.f.d.a.MessageLogCallBackImpl - Message : null Message : null 13:40:44.253 [pool-2-thread-1] ERROR c.f.d.a.AbstractDmipClient - Exception opening the connection: {} java.io.IOException: Connection Error 302 : Found at org.atmosphere.wasync.transport.WebSocketTransport.connectFutureException(WebSocketTransport.java:260) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.atmosphere.wasync.transport.WebSocketTransport.onFailure(WebSocketTransport.java:295) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.atmosphere.wasync.transport.WebSocketTransport.onThrowable(WebSocketTransport.java:114) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyResponseFuture.abort(NettyResponseFuture.java:345) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider.abort(NettyAsyncHttpProvider.java:1418) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider.exceptionCaught(NettyAsyncHttpProvider.java:1643) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:112) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline$DefaultChannelHandlerContext.sendUpstream(DefaultChannelPipeline.java:791) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.frame.FrameDecoder.exceptionCaught(FrameDecoder.java:377) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:112) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.http.HttpClientCodec.handleUpstream(HttpClientCodec.java:92) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:559) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireExceptionCaught(Channels.java:525) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.AbstractChannelSink.exceptionCaught(AbstractChannelSink.java:48) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.notifyHandlerException(DefaultChannelPipeline.java:658) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:566) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline$DefaultChannelHandlerContext.sendUpstream(DefaultChannelPipeline.java:791) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:296) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.frame.FrameDecoder.unfoldAndFireMessageReceived(FrameDecoder.java:459) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.callDecode(ReplayingDecoder.java:536) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.messageReceived(ReplayingDecoder.java:435) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:70) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.http.HttpClientCodec.handleUpstream(HttpClientCodec.java:92) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:559) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:268) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:255) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:88) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.process(AbstractNioWorker.java:108) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioSelector.run(AbstractNioSelector.java:318) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.run(AbstractNioWorker.java:89) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:178) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.util.ThreadRenamingRunnable.run(ThreadRenamingRunnable.java:108) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.util.internal.DeadLockProofWorker$1.run(DeadLockProofWorker.java:42) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_51] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [na:1.7.0_51] at java.lang.Thread.run(Thread.java:744) [na:1.7.0_51] Caused by: org.atmosphere.wasync.transport.TransportNotSupported: null at org.atmosphere.wasync.transport.WebSocketTransport.onStatusReceived(WebSocketTransport.java:199) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider$WebSocketProtocol.handle(NettyAsyncHttpProvider.java:2340) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider.messageReceived(NettyAsyncHttpProvider.java:1228) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:296) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.frame.FrameDecoder.unfoldAndFireMessageReceived(FrameDecoder.java:459) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.callDecode(ReplayingDecoder.java:536) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.messageReceived(ReplayingDecoder.java:435) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.http.HttpClientCodec.handleUpstream(HttpClientCodec.java:92) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:268) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:255) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:88) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.process(AbstractNioWorker.java:108) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioSelector.run(AbstractNioSelector.java:318) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.run(AbstractNioWorker.java:89) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:178) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] ... 3 common frames omitted 13:40:44.256 [pool-2-thread-1] INFO c.f.d.a.MessageLogCallBackImpl - Message : Connection Error 302 : Found Message : Connection Error 302 : Found 13:40:44.259 [New I/O worker #1] DEBUG c.n.h.c.p.netty.NettyResponseFuture - asyncHandler.onThrowable java.lang.Error: No suitable transport supported by the server at org.atmosphere.wasync.impl.AtmosphereSocket$1.on(AtmosphereSocket.java:94) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.atmosphere.wasync.impl.AtmosphereSocket$1.on(AtmosphereSocket.java:78) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.atmosphere.wasync.transport.TransportsUtil.matchFunction(TransportsUtil.java:117) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.atmosphere.wasync.transport.TransportsUtil.invokeFunction(TransportsUtil.java:73) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.atmosphere.wasync.transport.WebSocketTransport.onFailure(WebSocketTransport.java:296) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.atmosphere.wasync.transport.WebSocketTransport.onThrowable(WebSocketTransport.java:114) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyResponseFuture.abort(NettyResponseFuture.java:345) ~[dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider.abort(NettyAsyncHttpProvider.java:1418) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at com.ning.http.client.providers.netty.NettyAsyncHttpProvider.exceptionCaught(NettyAsyncHttpProvider.java:1643) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:112) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline$DefaultChannelHandlerContext.sendUpstream(DefaultChannelPipeline.java:791) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.frame.FrameDecoder.exceptionCaught(FrameDecoder.java:377) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:112) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.http.HttpClientCodec.handleUpstream(HttpClientCodec.java:92) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:559) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireExceptionCaught(Channels.java:525) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.AbstractChannelSink.exceptionCaught(AbstractChannelSink.java:48) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.notifyHandlerException(DefaultChannelPipeline.java:658) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:566) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline$DefaultChannelHandlerContext.sendUpstream(DefaultChannelPipeline.java:791) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:296) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.frame.FrameDecoder.unfoldAndFireMessageReceived(FrameDecoder.java:459) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.callDecode(ReplayingDecoder.java:536) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.replay.ReplayingDecoder.messageReceived(ReplayingDecoder.java:435) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.SimpleChannelUpstreamHandler.handleUpstream(SimpleChannelUpstreamHandler.java:70) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.handler.codec.http.HttpClientCodec.handleUpstream(HttpClientCodec.java:92) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:564) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.DefaultChannelPipeline.sendUpstream(DefaultChannelPipeline.java:559) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:268) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.Channels.fireMessageReceived(Channels.java:255) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.read(NioWorker.java:88) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.process(AbstractNioWorker.java:108) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioSelector.run(AbstractNioSelector.java:318) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.AbstractNioWorker.run(AbstractNioWorker.java:89) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.channel.socket.nio.NioWorker.run(NioWorker.java:178) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.util.ThreadRenamingRunnable.run(ThreadRenamingRunnable.java:108) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at org.jboss.netty.util.internal.DeadLockProofWorker$1.run(DeadLockProofWorker.java:42) [dmip-application-client-1.0.0.0.0-SNAPSHOT-jar.jar:na] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [na:1.7.0_51] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [na:1.7.0_51] at java.lang.Thread.run(Thread.java:744) [na:1.7.0_51] 13:40:44.260 [New I/O worker #1] DEBUG c.n.h.c.p.n.NettyAsyncHttpProvider - Closing Channel [id: 0x37b90e4a, /10.192.1.120:58603 => /10.192.1.120:80]

jfarcand commented 10 years ago

Please don't mix issue...what I want to see first is if rhe close works for you when you manually close AHX.

schandr commented 10 years ago

I tried two sets of code

1.final AtmosphereClient client = ClientFactory.getDefault().newClient(AtmosphereClient.class); RequestBuilder request = getRequestBuilder(client); DefaultOptionsBuilder builder = client.newOptionsBuilder(); builder.binary(true); builder.runtimeShared(false); DefaultOptions options = builder.build(); final Socket socketHandle = client.create(options); final AsyncHttpClient asyncClient = options.runtime();

2. final AtmosphereClient client = ClientFactory.getDefault().newClient(AtmosphereClient.class); final AsyncHttpClient asyncClient = new AsyncHttpClient(new AsyncHttpClientConfig.Builder().setMaxRequestRetry(0).build());
RequestBuilder request = getRequestBuilder(client); DefaultOptionsBuilder builder = client.newOptionsBuilder(); builder.binary(true); builder.runtime(asyncClient); builder.runtimeShared(false); DefaultOptions options = builder.build(); final Socket socketHandle = client.create(options);

The only difference between the two are the way I am getting the instance of AsyncHttpClient. In the first case I am able to connect, but after close, the FD is not closed In the second case, I am not even able to connect. The error stack in the previous comment is when I am not able to connect.

schandr commented 10 years ago

Team, Any updates on this one? I am still encountering issues in the deployed environments

schandr commented 10 years ago

I was able to get the AsyncHttpClient association with client to work with the below code asyncHttpClient = new AsyncHttpClient( new AsyncHttpClientConfig.Builder().setMaxRequestRetry(0) .setFollowRedirects(true).build()); final AtmosphereClient client = ClientFactory.getDefault().newClient( AtmosphereClient.class); RequestBuilder request = getRequestBuilder(client); DefaultOptionsBuilder builder = client.newOptionsBuilder(); builder.reconnect(false).binary(true); builder.runtime(asyncHttpClient,false); DefaultOptions options = builder.build(); socketHandle = client.create(options);

Currently monitoring the FDs for the socket.

jfarcand commented 9 years ago

Closing this issue as user error.