There is no requirement that an app can write to the directory where the internal version of a web app is stored in an app server

[EMAIL PROTECTED] wrote:

Maybe you could explain how this would work? Are you assuming that the
war/ear file is always unpacked into the local file system? Is that
guaranteed for a J2EE server?



No I cannot assume that, but if (and my guess it should be possible to
determine where a resource loaded from the classpath came from, e.g.
whether the URL contains a jar: protocol) then this would work. And if
not, it can obviously not be written. But for servlet containers like
Tomcat and Jetty, one can ensure that the web app is unpackaged before
it is started.


Even if the web app is exploded, are you sure that the web app has write access to the directory to which the servlet container has exploded it? I'm not saying it doesn't, I just wouldn't be surprised if some container didn't want the contents of that directory to change.

I don't think using an absolute path to the db is awfully ugly as long as it can be configured, e.g. as a context-param.

Reply via email to