https://bz.apache.org/bugzilla/show_bug.cgi?id=63872

--- Comment #3 from Steve Sanders <stevesander...@gmail.com> ---
(In reply to Steve Sanders from comment #2)
> (In reply to Kilian Felder from comment #1)
> > user@testsystem:/path/to/instance/webapps $ ls -l
> > :
> > lrwxrwxrwx  ...  myapp.war -> MyApp-4.10.5.0.war.r2308mod-20191017-2100
> > -rw-rw----  ...  MyApp-4.10.5.0.war.r2308mod-20191017-2100
> > :
> > It's not working this way (but was possible until 8.5.34). Here I point with
> > the symlink to the war-file which is in the webapps directory itself, and it
> > must not have the .war suffix because otherwise it would be exploded twice.
> > 
> > user@testsystem:/path/to/instance/webapps $ ls -l
> > :
> > lrwxrwxrwx  ...  myapp.war ->
> > ../MyApp-4.10.5.0.war.r2308mod-20191017-2100.war
> > :
> > It's working when I place the war-file one level higher and add the .war
> > suffix!
> > 
> > Why do you check for the .war suffix? When it's required to check for the
> > .war suffix you should do this maybe better before the call to
> > getCanonicalPath().
> 
> Looks like this got added in to ensure consistency of behavior according to
> the changelog. If I'm not mistaken though, the .war file extension has been
> requirement for very long time. It feels to me (a user not a contributor)
> that you were sort of abusing a bug to deploy your application this way in
> the past.
> 
> I'm assuming your aim here is to deploy your application with a different
> context root than what the actual file name is, so you use a symlink to give
> it the context you want. If thats correct - why not use META-INF/context.xml
> to define the context you want here?

Dug a bit deeper here - and my feelings on the use case aside - it is valid. It
also appears to have been fixed in 9.0.20. I'm uncertain if there are plans to
backport it to 8.5.X or not. But looking at the code, I THINK its possible to
do.

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to