atmosphere icon indicating copy to clipboard operation
atmosphere copied to clipboard

[atmosphere.js] long-polling XDR fails to suspend in IE9

Open nite23 opened this issue 14 years ago • 3 comments

A following problem appears,only with Internet Explorer, and only when using cross-domain connection:

After the client calls subscribe(), and issues HTTP GET request, server closes the connection and returns a response immediately, instead of leaving it suspended.

Tested with rest-chat example, on Atmosphere 1.0.0.beta4, GlassFish 3.1.2.2, Jersey 1.9.1, Java 7

Following client settings were used:

  • request.transport = 'long-polling';
  • request.enableXDR = true;
  • request.dropAtmosphereHeaders = true;
  • request.attachHeadersAsQueryString = true;

Here is the content of issued HTTP request, and corresponding response:

GET /test?X-Atmosphere-tracking-id=0&X-Atmosphere-Framework=1.0&X-Atmosphere-Transport=long-polling&X-Cache-Date=0&Content-Type=application/json HTTP/1.1 Accept: / Origin: http://omitted Accept-Language: cs-CZ UA-CPU: AMD64 Accept-Encoding: gzip, deflate User-Agent: Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Win64; x64; Trident/5.0) Host: omitted Connection: Keep-Alive Cache-Control: no-cache

HTTP/1.1 200 OK X-Powered-By: Servlet/3.0 JSP/2.2 (GlassFish Server Open Source Edition 3.1.2.2 Java/Oracle Corporation/1.7) Server: GlassFish Server Open Source Edition 3.1.2.2 X-Atmosphere-tracking-id: 47ed88bf-f25c-45f1-bb7c-49c9dc512475 Set-Cookie: JSESSIONID=82eca6b3b1ce07ded834e9cc461d; Path=/LivePlus; HttpOnly Expires: -1 Cache-Control: no-store, no-cache, must-revalidate Pragma: no-cache Content-Type: application/json Content-Length: 0 Date: Fri, 27 Jul 2012 11:25:07 GMT

And here is the packet trace:

  • 16 10.0.1.3 omitted HTTP GET /test?X-Atmosphere-tracking-id=0&X-Atmosphere-Framework=1.0&X-Atmosphere-Transport=long-polling&X-Cache-Date=0&Content-Type=application/json HTTP/1.1
  • 17 omitted 10.0.1.3 TCP http-alt > 55305 [ACK] Seq=1 Ack=450 Win=54 Len=0
  • 18 10.0.1.3 omitted TCP 55305 > http-alt [FIN, ACK] Seq=450 Ack=1 Win=16583 Len=0
  • 19 omitted 10.0.1.3 HTTP HTTP/1.1 200 OK
  • 20 omitted 10.0.1.3 TCP http-alt > 55305 [FIN, ACK] Seq=498 Ack=451 Win=54 Len=0
  • 21 10.0.1.3 omitted TCP 55305 > http-alt [RST, ACK] Seq=451 Ack=498 Win=0 Len=0

nite23 avatar Jul 27 '12 11:07 nite23

Looking

jfarcand avatar Jul 27 '12 13:07 jfarcand

OK since the suspend operation set a response of content-length == 0, IE throw an error. I've added a workaround.

jfarcand avatar Jul 27 '12 18:07 jfarcand

issue remains in beta5

  • 203 5.570597000 10.0.1.3 omitted HTTP 497 GET /AtmTest/ws?X-Atmosphere-tracking-id=0&X-Atmosphere-Framework=1.0&X-Atmosphere-Transport=long-polling&X-Cache-Date=0&Content-Type=application/json HTTP/1.1
  • 204 5.589448000 omitted 10.0.1.3 TCP 60 http-alt > 61015 [ACK] Seq=1 Ack=444 Win=6912 Len=0
  • 205 6.566796000 10.0.1.3 omitted TCP 54 61015 > http-alt [RST, ACK] Seq=444 Ack=1 Win=0 Len=0

nite23 avatar Jul 28 '12 05:07 nite23