cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daniel Fagerstrom <>
Subject Re: [Vote] Let the environment interfaces extend the javax.servlet.http ones
Date Tue, 07 Feb 2006 18:31:46 GMT
Sylvain Wallez skrev:
> Carsten Ziegeler wrote:
>> Sylvain Wallez wrote:
>>> One of the possible solutions is to make generally and officially 
>>> available the ServletRequest and ServletResponse entries of the 
>>> object model that are populated by the HttpEnvironment. This creates 
>>> a migration path towards the standard servlet interfaces.
>> They are already officially available in an http environment, so we could
>> end up with the question what to do in other environments. Generating
>> them?
> Yep. Just as our HttpRequest is a wrapper around the ServletRequest, 
> we'll have to write wrappers around oace.Request that implement 
> jsh.HttpServletRequest ;-)

IIUC. the only place where we need to support our environment interfaces
from a compatibility POV is in the object model. It would be enough to
introduce a thin wrapper in the object model and do all processing in
the rest of Cocoon based on the j.s.h interfaces.

For processing within the sitemap processor and pipelines we would need
a wrapper around jsh.HttpServletRequest that extends the input one with
the Cocoon specific getSitemap* methods (and possibly some more
methods). All functionality from oaceh.HttpRequest etc would be moved to
the new wrapper that implements jsh.HttpServletRequest, and
oaceh.HttpRequest would become a "pure" wrapper.

> Hmm... now should this wrapper implement _Http_ServletRequest, or just 
> SerlvetRequest? The servlet API was designed to be extend in areas other 
> than http, but this never happened (e.g. portlets). Don't know...

I think it should implement HttpServletRequest, the ServletRequest 
doesn't know anything about the request URL, I wonder if that would make 
sense in Cocoon.


View raw message