Re: Proposed new CometEvent.notify method

2007-05-03 Thread Remy Maucherat
Filip Hanik - Dev Lists wrote: Ok, I'll try something in the meantime in CoyoteAdapter, since it's trivial (and I think does all that is needed at this point). The available() has a side effect, if there is a partial or non valid chunked header (ie the client also sends some garbage), available(

Re: Proposed new CometEvent.notify method

2007-05-03 Thread Filip Hanik - Dev Lists
Remy Maucherat wrote: Filip Hanik - Dev Lists wrote: It's the contract of this API (which is blocking IO), it's not me ;) I hear you loud and clear, although the API doesn't specify as 0 being an illegal value, it is assumed in many places in the code that the value is either -1 or >0 http://j

svn commit: r535038 - in /tomcat/tc6.0.x/trunk/java/org/apache/catalina/startup: Constants.java DigesterFactory.java

2007-05-03 Thread remm
Author: remm Date: Thu May 3 17:19:56 2007 New Revision: 535038 URL: http://svn.apache.org/viewvc?view=rev&rev=535038 Log: - Add some xsds to the constants. Modified: tomcat/tc6.0.x/trunk/java/org/apache/catalina/startup/Constants.java tomcat/tc6.0.x/trunk/java/org/apache/catalina/startu

svn commit: r535035 - /tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java

2007-05-03 Thread remm
Author: remm Date: Thu May 3 17:04:39 2007 New Revision: 535035 URL: http://svn.apache.org/viewvc?view=rev&rev=535035 Log: - Use the better IOException type (any other exception is totally unexpected). Modified: tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector/CoyoteAdapter.java Modi

Re: Proposed new CometEvent.notify method

2007-05-03 Thread Remy Maucherat
Filip Hanik - Dev Lists wrote: It's the contract of this API (which is blocking IO), it's not me ;) I hear you loud and clear, although the API doesn't specify as 0 being an illegal value, it is assumed in many places in the code that the value is either -1 or >0 http://java.sun.com/j2se/1.5.0/

svn commit: r535030 - in /tomcat/tc6.0.x/trunk/java/org/apache/catalina/connector: CoyoteAdapter.java InputBuffer.java Request.java

2007-05-03 Thread remm
Author: remm Date: Thu May 3 16:54:31 2007 New Revision: 535030 URL: http://svn.apache.org/viewvc?view=rev&rev=535030 Log: - Remove the didRead flag (an error checking hack). - If there is a read event, do at least one read on the connector (the buffer is necessarily empty, otherwise there wou

Re: Proposed new CometEvent.notify method

2007-05-03 Thread Filip Hanik - Dev Lists
Remy Maucherat wrote: Filip Hanik - Dev Lists wrote: No, I don't agree with reading bytes in the lower layer as it would swallow problems even more than doing it in the adapter without any additional benefit (BTW, read cannot return 0). There's also a likely problem that it would require addit

Re: Proposed new CometEvent.notify method

2007-05-03 Thread Remy Maucherat
Filip Hanik - Dev Lists wrote: No, I don't agree with reading bytes in the lower layer as it would swallow problems even more than doing it in the adapter without any additional benefit (BTW, read cannot return 0). There's also a likely problem that it would require additional structures to hol

Re: Proposed new CometEvent.notify method

2007-05-03 Thread Filip Hanik - Dev Lists
Remy Maucherat wrote: Filip Hanik - Dev Lists wrote: yes, but that's ok. the sequence would be this a) available() == 1 b) InputStream.read() == 0 c) available() == 0 what this would mean, is that available()==1 means there is data fetched from the actual socket, may or may not translate into u

svn commit: r534930 - /tomcat/tc6.0.x/trunk/java/org/apache/catalina/core/AprLifecycleListener.java

2007-05-03 Thread fhanik
Author: fhanik Date: Thu May 3 09:43:35 2007 New Revision: 534930 URL: http://svn.apache.org/viewvc?view=rev&rev=534930 Log: Fix the bug in AprLifecycleListener, the value of SSLEngine is never transferred to the listener. Patch submitted by mturk Modified: tomcat/tc6.0.x/trunk/java/org/apa

Re: Proposed new CometEvent.notify method

2007-05-03 Thread Remy Maucherat
Filip Hanik - Dev Lists wrote: yes, but that's ok. the sequence would be this a) available() == 1 b) InputStream.read() == 0 c) available() == 0 what this would mean, is that available()==1 means there is data fetched from the actual socket, may or may not translate into user data. In the sequen

Re: Proposed new CometEvent.notify method

2007-05-03 Thread Remy Maucherat
Filip Hanik - Dev Lists wrote: Remy Maucherat wrote: Filip Hanik - Dev Lists wrote: Oh by the way, before we start doing all this, I'd really like to push out another "stable" 6.0. There's been tons of bug fixes, and before we put everything on the chopping block again, lets push those out.

Re: Proposed new CometEvent.notify method

2007-05-03 Thread Filip Hanik - Dev Lists
Remy Maucherat wrote: Filip Hanik - Dev Lists wrote: Oh by the way, before we start doing all this, I'd really like to push out another "stable" 6.0. There's been tons of bug fixes, and before we put everything on the chopping block again, lets push those out. It's a possibility, but the cur

DO NOT REPLY [Bug 42309] - Request: support for NIO in Embedded Tomcat

2007-05-03 Thread bugzilla
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUGĀ· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT . ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED ANDĀ· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bu

Re: Proposed new CometEvent.notify method

2007-05-03 Thread Filip Hanik - Dev Lists
Remy Maucherat wrote: Filip Hanik - Dev Lists wrote: a) make sure it is not registered for READ event b) call event.close() c) call event.notify() - yields a END or NOTIFY event You need to be doing stuff in your servlet somewhere in between too. yes, that's what I meant, this would be in the

Re: Proposed new CometEvent.notify method

2007-05-03 Thread Remy Maucherat
Filip Hanik - Dev Lists wrote: Oh by the way, before we start doing all this, I'd really like to push out another "stable" 6.0. There's been tons of bug fixes, and before we put everything on the chopping block again, lets push those out. It's a possibility, but the current svn is still in the

svn commit: r534913 - /tomcat/tc6.0.x/trunk/java/org/apache/catalina/startup/Embedded.java

2007-05-03 Thread fhanik
Author: fhanik Date: Thu May 3 08:49:09 2007 New Revision: 534913 URL: http://svn.apache.org/viewvc?view=rev&rev=534913 Log: Ability to create a connector using a custom protocol specification for embedded. Fix for bug 42309 Modified: tomcat/tc6.0.x/trunk/java/org/apache/catalina/startup/Em

Re: Proposed new CometEvent.notify method

2007-05-03 Thread Remy Maucherat
Filip Hanik - Dev Lists wrote: a) make sure it is not registered for READ event b) call event.close() c) call event.notify() - yields a END or NOTIFY event You need to be doing stuff in your servlet somewhere in between too. 1. Change "boolean comet =" to "int comet =" or to a list of enum, ba

Re: Proposed new CometEvent.notify method

2007-05-03 Thread Filip Hanik - Dev Lists
Remy Maucherat wrote: Remy Maucherat wrote: Hi, To more conveniently support some use cases, a new notify method could be added to the event. This would do an action callback and call a new method in the Poller class would add the socket to a structure like the socket add list. The comet pol

Re: svn commit: r534695 - /tomcat/tc6.0.x/trunk/java/org/apache/coyote/http11/Http11NioProcessor.java

2007-05-03 Thread Filip Hanik - Dev Lists
Remy Maucherat wrote: [EMAIL PROTECTED] wrote: Author: fhanik Date: Wed May 2 19:35:56 2007 New Revision: 534695 URL: http://svn.apache.org/viewvc?view=rev&rev=534695 Log: Same fix as for the APR processor, although wouldn't this flag be set on the "recycle" method Yes, I did not commit the

Re: Proposed new CometEvent.notify method

2007-05-03 Thread Filip Hanik - Dev Lists
Remy Maucherat wrote: Remy Maucherat wrote: Hi, To more conveniently support some use cases, a new notify method could be added to the event. This would do an action callback and call a new method in the Poller class would add the socket to a structure like the socket add list. The comet pol

Re: svn commit: r534695 - /tomcat/tc6.0.x/trunk/java/org/apache/coyote/http11/Http11NioProcessor.java

2007-05-03 Thread Remy Maucherat
[EMAIL PROTECTED] wrote: Author: fhanik Date: Wed May 2 19:35:56 2007 New Revision: 534695 URL: http://svn.apache.org/viewvc?view=rev&rev=534695 Log: Same fix as for the APR processor, although wouldn't this flag be set on the "recycle" method Yes, I did not commit the same patch for the NIO