tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Julien BARRET" <julien.bar...@advantys.fr>
Subject WebApps and getRealPath...
Date Mon, 19 Jun 2000 10:04:08 GMT
Hi,

I have 2 web applications on my tomcat server.

My first webapp (lets call it rootapp) is "/" [accessible with http://server/rootappFile.jsp]
My second webapp (lets call it app2) is "/app2" [accessible with http://server/app2/app2File.jsp]

If a servlet running in app2 tries to do a getRealPath on a file located under "/" (e.g getRealPath("/file.txt"))
then getRealPath returns a wrong value. I believe this is normal, due to the separation between
webapps contexts.

But if a servlet running in rootapp do a getRealPath on a file located in app2 (e.g getRealPath("/app2/file.txt"))
then getrealpath returns the right value...

So is the root application a "special" webapp with sort of "super user" rights ? 



Regards,

Julien BARRET (still working on realPaths...)

ADVANTYS
julien.barret@advantys.fr


Mime
View raw message