cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "shenoy, nitin" <nshe...@telegea.com>
Subject ServletConfig.getRealPath
Date Sat, 19 Jan 2002 01:08:34 GMT
Hi Folks,

I think Cocoon is a very powerful framework and I respect all the hard work
and effort that has gone into the making of Cocoon.

Now for my question :)

Is the decision to use ServletConfig.getRealPath in cocoon a good design
decision? From the Servlet 2.2 spec ..... "when the web application is
executed from an archive, on a remote file system not accessible locally, or
in a database, these methods must return null."

BEA Weblogic returns null in a War file format (as most of you folks are
probably aware already) and a ton of Cocoon users are screaming all over the
place about not being able to deploy Cocoon in a war format.

I wanna volunteer to try and fix (or is adapt the right word?) Cocoon so
that it works in war format (only 13 files use the getRealPath method) under
weblogic but I also think I can do a better job if I understand the
perspective correctly.

Please do bear with me if the above topic is a non issue, but I do see a lot
of postings on the Cocoon users list and the BEA weblogic list.

Regards,
Nitin Shenoy


Resources - 

Servlet 2.2 spec 

5.5 Path Translation Methods

There are two convenience methods in the HttpServletRequest interface which
allow the
Developer to obtain the file system path equivalent to a particular path.
These methods are:
. getRealPath
. getPathTranslated

The getRealPath method takes a String argument and returns a String
representation of a
file on the local file system to which that path corresponds. The
getPathTranslated method
computes the real path of the pathInfo of this request.

In situations where the servlet container cannot determine a valid file path
for these methods, such
as when the web application is executed from an archive, on a remote file
system not accessible
locally, or in a database, these methods must return null.


---------------------------------------------------------------------
To unsubscribe, e-mail: cocoon-dev-unsubscribe@xml.apache.org
For additional commands, email: cocoon-dev-help@xml.apache.org


Mime
View raw message