tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 38131] - WatchedResource does not work if app is outside "webapps"
Date Tue, 03 Jul 2007 15:34:09 GMT
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG·
RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT
<http://issues.apache.org/bugzilla/show_bug.cgi?id=38131>.
ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND·
INSERTED IN THE BUG DATABASE.

http://issues.apache.org/bugzilla/show_bug.cgi?id=38131


plynch@apache.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |NEW




------- Additional Comments From plynch@apache.org  2007-07-03 08:34 -------
In my tests using tomcat 6.0.13, JDK 1.6, when the path in the WatchedResource
is relative path, the absolute path interpreted by the code as written for the
relative path will be an absolute path to relative to the JVM startup directory.
Obviously something is very quirky in there. Since the path will then most
likely point to an invalid resource, it will not be watched and there is no
warning give to the user either. In this case addWatchedResource is given a
'null' docBase.

The code in question is in HostConfig.deployDescriptor().

Suggested code improvements:
o for descriptors that explicitly specify an absolute docBase, pass it to the
addWatchedResource method instead of 'null'
o print warning if watched resource evaluated path points to a resource that
does not exist

I came up with a fix but I was discouraged to not find any existing unit tests
to verify regression. If there are any please tell me so I can verify the patch.


-- 
Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.

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


Mime
View raw message