tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marius Scurtescu <mar...@sxip.com>
Subject Re: Multiple source directories for one webapp
Date Fri, 03 Jun 2005 15:43:35 GMT
Laurent Brucher wrote:
> Hi all,
> 
> I guess this is not really new, but I haven't seen any concrete solution nor
> much discussion about it.
> 
> So here's the problem:
> one webapp composed of multiple pieces (jsp, html, css, etc.) located at
> various locations on the filesystem.
> 
> I know, this goes against the servlet spec. but I've had a need for this
> many times by now, especially under
> development (our projects are broken down into various modules, each
> contributing to creating a final webapp).
> For production, an ant task will do the job putting all the pieces correctly
> together. Under development,
> I find it unpractical to run an ant task every time a jsp has been modified.
> 
> We started looking into replacing the resource context with a modified
> version of the FileDirContext, with
> good results so far. This modified version acts as a directory mapper and,
> given a requested resource, provides
> its correct location on the filesystem.
> 
> Before continuing further in that direction, I was wondering whether there
> may be alternatives solutions
> to the problem, and also what you guys think about all this?

It all depends on what OS and what editor you use. Under Unix using 
symbolic links could be a solution.

I am not familiar with rsync, but you could use a tool like that to keep 
two folders in sync. It should be possible to setup a process that is 
watching your working folder and every time a file changes to copy it 
over to the deployed web app folder.

I had a similar problem a while back (Windows/IDEA) and I ended up using 
a plugin that will copy the JSP file to the right location when hitting 
  a special key. I found this plugin to be very effective.

> 
> Thanks,
> Laurent.

Marius


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message