this sounds pretty interesting. As I did not even know before there existed such a wrapper, I am hardly the right person to evaluate your work. Though, what I can offer is you send this to me directly (not to the list to avoid branching) and I check it into the proposals section in the CVS for public review.
Oliver
Richard Unger wrote:
Hi!
In Brief: Wrappers for individual contexts rather than hosts MixedDirContext JNDI wrapper providing access to slide and file system at same time.
Longer answers inserted between your text...
On Fri, 2003-11-14 at 15:07, Stefano Mazzocchi wrote:
On 14 Nov 2003, at 11:32, Richard Unger wrote:
Hi!
I was a little unhappy with the Tomcat integration, and I have written such a
wrapper, which I would like to contribute.
what does the wrapper do?
I have several wrappers.
The original slide wrappers set up an entire tomcat host with the slide
domain, mapping each namespace to a context. There were 2 such wrappers:
one that set up each context so it would load its resources from the
slide namespace it was associated with, but otherwise act as a normal
tomcat context, and another wrapper that set up each context as a WEBDAV
enabled context mapping to the namespace (ie with the webdav servlet
behind it).
That was the way it worked.
I found this too restrictive, and added wrappers for an individual tomcat context instead of the entire host, permitting one to configure tomcat flexibly with webdav and slide resource contexts, as well as traditional web application contexts, as one chooses.
In addition I added/fixed the ability to map a slide resource or webdav context to a subdirectory of the specified namespace.
In order to implement the access to slide resources from a 'normal' tomcat context, a jndi resource wrapper (SlideDirContext wrapper) was written. This provides resources for the context, loading them from slide.
Originally tomcat would load things from the WEB-INF directory of the context on disk, allowing web applications to be installed there, and then use the slide resources once the context was started. This behaviour changed at some point, loading all resources (even the WEB-INF dir) from slide when the wrapper was installed. Since I found it convenient, especially during testing, to keep jars on the file system and not have to load them into slide before starting the resource context, I wrote a MixedDirContext JNDI wrapper, which loads resources first from slide, and if not found there, from the filesystem. Its very useful for development.
Where am I going with all this? I wanted to use more of WEBDAVs features
to implement a CMS: I install the same slide namespace 3 times into tomcat:
Once for public viewing as a resource context.
Once for editing via online forms/webapps, also as a resource context,
but the editing webapps talking to slide.
Once for editing via webdav, as a webdav context.
By enabling version control, and using the WEBDAV workspace feature, I can have the public and edit views show different versions of the same namespace. The edit context always maps to the main namespace (HEAD revision), while the public context maps to a workspace within the namespace, which is filled with the released version of files using the WEBDAV versioncontrol command.
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
