You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by bu...@apache.org on 2010/09/22 20:11:32 UTC

DO NOT REPLY [Bug 49978] New: WebappLoader throws exception if workDir already exists (when unpackWARs=false)

https://issues.apache.org/bugzilla/show_bug.cgi?id=49978

           Summary: WebappLoader throws exception if workDir already
                    exists (when unpackWARs=false)
           Product: Tomcat 7
           Version: trunk
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Catalina
        AssignedTo: dev@tomcat.apache.org
        ReportedBy: jfrederic@dmotorworks.com


In WebappLoader.setRepositories(), if the war is not unpacked, it tries to
create a directory /WEB-INF/classes inside the workDir.  If that directory
already exists, an error is thrown and the webapp does not start.

This is a change from 5.5, which didn't check the return value of
classRepository.mkdirs().  mkdirs() returns false if the directories already
exist.  I doubt it was the intention here.  Probably the intention was to throw
an exception if the directory could not be created, rather than if it already
existed.

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

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


DO NOT REPLY [Bug 49978] WebappLoader throws exception if workDir already exists (when unpackWARs=false)

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=49978

kristof batizy <kr...@batizy.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |kristof@batizy.com

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

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


DO NOT REPLY [Bug 49978] WebappLoader throws exception if workDir already exists (when unpackWARs=false)

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=49978

kristof batizy <kr...@batizy.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|FIXED                       |

--- Comment #2 from kristof batizy <kr...@batizy.com> 2011-01-28 18:05:22 EST ---
I am seeing this, or similar, on Windows XP (32 bit) 7.0.6 under the same
conditions (unpackWars=false)

SEVERE: LifecycleException
java.io.IOException: Failed to copy resources
        at
org.apache.catalina.loader.WebappLoader.setRepositories(WebappLoader.java:890)
        at
org.apache.catalina.loader.WebappLoader.startInternal(WebappLoader.java:601)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
        at
org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:4857)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
        at
org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:812)
        at
org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:787)
        at
org.apache.catalina.core.StandardHost.addChild(StandardHost.java:583)
        at
org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:917)
        at
org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:715)
        at
org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:469)
        at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1294)
        at
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
        at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
        at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:89)
        at
org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:343)
        at
org.apache.catalina.util.LifecycleBase.setState(LifecycleBase.java:323)
        at
org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1043)
        at
org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:750)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
        at
org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1035)
        at
org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:291)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
        at
org.apache.catalina.core.StandardService.startInternal(StandardService.java:442)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
        at
org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:674)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:145)
        at org.apache.catalina.startup.Catalina.start(Catalina.java:600)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
        at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:597)
        at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:303)
        at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:431)

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

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


DO NOT REPLY [Bug 49978] WebappLoader throws exception if workDir already exists (when unpackWARs=false)

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=49978

Mark Thomas <ma...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|REOPENED                    |RESOLVED
         Resolution|                            |FIXED

--- Comment #3 from Mark Thomas <ma...@apache.org> 2011-01-28 19:01:31 EST ---
Yep, there was another similar issue in the same area. Fixed in 7.0.x and will
be in 7.0.7 onwards.

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

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


DO NOT REPLY [Bug 49978] WebappLoader throws exception if workDir already exists (when unpackWARs=false)

Posted by bu...@apache.org.
https://issues.apache.org/bugzilla/show_bug.cgi?id=49978

Mark Thomas <ma...@apache.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|                            |FIXED

--- Comment #1 from Mark Thomas <ma...@apache.org> 2010-10-07 10:22:32 EDT ---
Fixed in trunk and will be in 7.0.4 onwards.

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

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