Issue Details (XML | Word | Printable)

Key: GDS-620
Type: Bug Bug
Status: Resolved Resolved
Resolution: Won't Fix
Priority: Major Major
Assignee: Franck Wolff
Reporter: Ori Dagan
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
GraniteDS

Gravity servlet3 not working well wiht glassfish v3

Created: 28/Jan/10 01:02 PM   Updated: 30/Aug/10 02:09 PM   Resolved: 30/Aug/10 02:09 PM
Component/s: Gravity
Affects Version/s: 2.1.0_RC2
Fix Version/s: None

Environment: Glassfish v3 with patch


 Description  « Hide
I filed a bug in glassfish regarding AsyncContext.complete() not working in some scenarios:
https://glassfish.dev.java.net/issues/show_bug.cgi?id=11359
This was fixed and a patch was provided by the grizzly team.
I applied the patch and now Gravity is not working properly. In the log I am getting:

[#|2010-01-28T13:25:22.604+0200|WARNING|glassfishv3.0|org.granite.gravity.servlet3.AsyncChannel|_ThreadID=24;_ThreadName=Thread-1;|Got a new non null asyncContext org.apache.catalina.connector.AsyncContextImpl@4a54c7 while current asyncContext org.apache.catalina.connector.AsyncContextImpl@4a54c7 isn't null|#]

[#|2010-01-28T13:25:22.619+0200|WARNING|glassfishv3.0|org.granite.gravity.servlet3.AsyncChannel|_ThreadID=25;_ThreadName=Thread-1;|Got a new non null asyncContext org.apache.catalina.connector.AsyncContextImpl@9f4306 while current asyncContext org.apache.catalina.connector.AsyncContextImpl@9f4306 isn't null|#]

[#|2010-01-28T13:25:22.637+0200|WARNING|glassfishv3.0|org.granite.gravity.servlet3.AsyncChannel|_ThreadID=24;_ThreadName=Thread-1;|Got a new non null asyncContext org.apache.catalina.connector.AsyncContextImpl@187242e while current asyncContext org.apache.catalina.connector.AsyncContextImpl@187242e isn't null|#]
.
.
.
repeated hundreds of times.

The bug in glassfish was that the response was not actually commited when calling complete() and thus not reaching the client. I suspect that now that it does reach the client, it tries to reconnect but the previous AsyncContext is still referenced by the gravity AsyncChannel.

To apply the patch, replace grizzly-utils.jar and grizzly-http.jar in the modules directory and delete the osgi cache from <domaindir>/osgi-cache/felix

Franck Wolff added a comment - 09/Feb/10 01:49 PM
I think we will wait for a GF3 preview integrating this change before changing the GDS Servlet 3 code. Meanwhile, you may turn off the warning message or (better) patch Gravity and send us your modifications...

William Draï added a comment - 30/Aug/10 02:09 PM
Problem not present with GlassFish 3.0.1 final.
Seems an issue in GF preview.