On Mon, 7 May 2001, Dan Milstein wrote:

> Henri,
> 
> Lots of good stuff.  A few ideas/possibilities:
> 
>  1) We've talked about specifying a response packet to indicate that the
> engine (or the web server) doesn't recognize a packet sent over.  This would
> allow us much more flexiblity to add packet types to ajpv14, without having
> to make ajpv15,16, etc.  

+1

In other words - both ends should deal with unknown packets - maybe by
sending back an "UNIMPLEMENTED" message. 


>  2) What about specifying a separate, out of band control socket
> connection?  If the web server opened up two connections, 1 for data, one
> for control, then we could have much better communication from the engine to
> the server (if it was shutting down contexts, for example).  We could also
> have a heartbeat without interfering with the data channel.

I'm not sure - but I can see some benefits.

Right now we have (almost) bidirectional communication - the protocol is
based on message passing, and sort of "token"-based: 
each side sends a message, then waits for a message.

The main reason for that is the single-threaded web server. ( Apache1.3,
maybe other servers ). It is a bit difficult to deal with 2 connections in
a single threaded env ( while keeping the code as simple as possible ).
My feeling is that for most needs of a servlet container we can deal with
the single socket protocol. I don't know any (major) use case or feature
of tomcat that would require the second socket.

( that doesn't mean I'm -1 on such thing )

Costin







Reply via email to