"Remy Maucherat" <[EMAIL PROTECTED]> wrote in message +1 for doing this in the Catalina code. Doing it in the Connector code would mean that CoyoteConnector code for older TC versions would languish off in a branch.
They have the same name :( I was obviously talking about the o.a.catalina.(Http)Request/Response that have been causing me pain for so long, and the instanceof which have been hurting my eyes.
- the current valve design mirrors the filters, but is actually different in what it can do (now that filters can work in request dispatchers), so I don't see the point of using the same pattern anymore; using the model from Tomcat pre-4.0 (yes, I know, it's old ;) ) would lower the number method calls and reduce significantly the stack
trace
I'm probably the number 2 fan of the Tomcat 3.3 API ;-), but it still has its own set of drawbacks (e.g. it is very sensitive to editing server.xml). Awhile back, Costin proposed using something along the lines of the Axis Handlers (which are sort of a cross between the Catalina Valves and the TC 3 Interceptors). Even if it isn't the Axis model, IMHO the ideal API would combine both the strict chain of command of the Valves with flexability of the Listener-like Interceptors.
I think the valve is the right pattern, so thanks Craig :) The only thing is that we shouldn't have the ValveContext which adds complexity (worthless IMO, as we don't need the extra robustness for our proprietary API, esp since its realm of application is getting lower due to the spec improvements), and we should only have next.invoke(). I regret Craig decided to change that without much asking right before 4.0 final, because it definitely had a cost in performance (it's much better now, but not zero either), and we could no longer break the API.
As for the listeners and stuff, I think Costin proposed using JMX. We'll need to make everything JMX if we want to do that, and fix a few things in commons-modeler.
Another thing is that we might want to write the next Tomcat for JDK 1.5.
Rémy
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]