tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Willem Fibbe <wil...@realworks.nl>
Subject Re: Handling of CometEvents regarding order (Tomcat 6 and 7)
Date Wed, 02 Nov 2011 14:09:28 GMT
Hi,

Thanks for your reply.
Just wanted to confirm the following:

On 26/10/2011 11:57, Mark Thomas wrote:
> On 25/10/2011 10:57, Willem Fibbe wrote:
> > Now for my questions: 1 - Can anybody confirm this lifecycle? If I
> > read the AIO documentation, a typical lifecycle would be: Begin ->
> > Read -> ... -> Error or End
> 
> That would be my expectation.
> 
> > However: - in Tomcat 6 I get the CometEnd twice.
> 
> I think the second CometEnd is a bug.

I suspect too. If I read the changelog for Tomcat 7.0.7 for Coyote I see that
this issue has been resolved there.
Maybe something similar is happening in Tomcat 6 also (I verified it for 6.0.29 and 6.0.33).

> 
> > - in Tomcat 7 I get a second CometRead, but never a CometError or
> > CometEnd (see next question)
> > 
> > 2 - Related to the first question, how should we handle the second
> > CometRead event in Tomcat 7? We tried two ways: - check whether the
> > CometEvent was already closed, and if so just return out of the
> > method - just try reading from the InputStream always when CometRead
> > occurs. This means that the second CometRead results in an
> > IOException ("Stream closed") (even reading a single byte)...
> > however, Tomcat should catch this and should fire a CometError
> > event.. yet, we don't see this CometError triggered in this case.
> 
> That looks like a bug to me. It may be related to [1]. You might want to
> try running against a locally built 7.0.x to see if the issue is fixed.
> If not, create a bug report.
> 
> Mark
> 
> [1] https://issues.apache.org/bugzilla/show_bug.cgi?id=51881

I built a new Tomcat 7.0.23 and now the second CometRead doesn't occur. Instead,
a CometEnd event is fired properly, so this seems to be fixed.

Thanks,
Willem

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message