On 21/06/2011 13:00, Konstantin Kolinko wrote: > Why setting socket reference in InputBuffer and OutputBuffer is > "unnecessary" here in async processing, but is still present for the > non-async case.
Because during the processing of a request, asyncDispatch() can only ever be called after process(). > I do not understand why you removed the code. Partly as the code is unnecessary, but mainly as a step towards being able to pull up asyncDispatch(). Mark > > > 2011/6/20 <ma...@apache.org>: >> Author: markt >> Date: Mon Jun 20 14:24:19 2011 >> New Revision: 1137638 >> >> URL: http://svn.apache.org/viewvc?rev=1137638&view=rev >> Log: >> Remove unnecessary code. >> >> Modified: >> tomcat/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java >> tomcat/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java >> >> Modified: tomcat/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java >> URL: >> http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java?rev=1137638&r1=1137637&r2=1137638&view=diff >> ============================================================================== >> --- tomcat/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java >> (original) >> +++ tomcat/trunk/java/org/apache/coyote/http11/Http11AprProcessor.java Mon >> Jun 20 14:24:19 2011 >> @@ -343,15 +343,8 @@ public class Http11AprProcessor extends >> >> } >> >> - /* Copied from the AjpProcessor.java */ >> - public SocketState asyncDispatch(SocketWrapper<Long> socket, >> - SocketStatus status) { >> >> - // Setting up the socket >> - this.socket = socket; >> - long socketRef = socket.getSocket().longValue(); >> - inputBuffer.setSocket(socketRef); >> - outputBuffer.setSocket(socketRef); >> + public SocketState asyncDispatch(SocketStatus status) { >> >> RequestInfo rp = request.getRequestProcessor(); >> try { >> >> Modified: tomcat/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java >> URL: >> http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java?rev=1137638&r1=1137637&r2=1137638&view=diff >> ============================================================================== >> --- tomcat/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java >> (original) >> +++ tomcat/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java Mon >> Jun 20 14:24:19 2011 >> @@ -230,7 +230,7 @@ public class Http11AprProtocol extends A >> SocketState state = SocketState.CLOSED; >> do { >> if (processor.isAsync() || state == >> SocketState.ASYNC_END) { >> - state = processor.asyncDispatch(socket, status); >> + state = processor.asyncDispatch(status); >> } else if (processor.comet) { >> state = processor.event(status); >> } else { >> > > Best regards, > Konstantin Kolinko > > --------------------------------------------------------------------- > To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org > For additional commands, e-mail: dev-h...@tomcat.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org