Uploaded image for project: 'Codehaus Cargo'
  1. Codehaus Cargo
  2. CARGO-865

The remote cargo-jetty-deployer does not work with Jetty 7.2.0

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.0.4
    • Fix Version/s: 1.0.5
    • Component/s: Jetty
    • Labels:
      None
    • Environment:

      Ubuntu 10.10 x86_64

      Description

      Here's what I exactly did:
      1. Download cargo-jetty-7-and-onwards-deployer-1.0.4.war from here: http://repo1.maven.org/maven2/org/codehaus/cargo/cargo-jetty-7-and-onwards-deployer/1.0.4/cargo-jetty-7-and-onwards-deployer-1.0.4.war
      2. Put cargo-jetty-7-and-onwards-deployer-1.0.4.war into JETTY_HOME/webapps
      3. Start Jetty (I installed the latest jetty-distribution-7.2.0.v20101020.tar.gz)
      4. I get the following from the jetty log (JETTY_HOME/logs/stderrorout.log):

      2010-11-09 16:52:00.454:INFO::JMX Remote URL: service:jmx:rmi://ip-10-122-33-163/jndi/rmi://localhost:1099/jettyjmx
      2010-11-09 16:52:00.701:INFO::jetty-7.2.0.v20101020
      2010-11-09 16:52:00.716:INFO::Deployment monitor /usr/local/jetty/jetty-distribution-7.2.0.v20101020/webapps at interval 0
      2010-11-09 16:52:00.718:INFO::Deployable added: /usr/local/jetty/jetty-distribution-7.2.0.v20101020/webapps/cargo-jetty-7-and-onwards-deployer-1.0.4.war
      2010-11-09 16:52:00.844:INFO::Copying WEB-INF/classes from jar:file:/usr/local/jetty/jetty-distribution-7.2.0.v20101020/webapps/cargo-jetty-7-and-onwards-deployer-1.0.4.war!/WEB-INF/classes/ to /tmp/jetty-0.0.0.0-80-cargo-jetty-7-and-onwards-deployer-1.0.4.war-_cargo-jetty-7-and-onwards-deployer-1.0.4-any-/webinf/WEB-INF/classes
      2010-11-09 16:52:00.997:WARN::Config error at <New id="deployerservlet" class="org.codehaus.cargo.deployer.jetty.DeployerServlet"><Arg><Ref id="serverObject"/></Arg></New> java.lang.reflect.InvocationTargetException
      2010-11-09 16:52:00.997:WARN::Failed startup of context WebAppContext@4edc41c5@4edc41c5/cargo-jetty-deployer,[file:/tmp/jetty-0.0.0.0-80-cargo-jetty-7-and-onwards-deployer-1.0.4.war-_cargo-jetty-7-and-onwards-deployer-1.0.4-any-/webinf/, jar:file:/usr/local/jetty/jetty-distribution-7.2.0.v20101020/webapps/cargo-jetty-7-and-onwards-deployer-1.0.4.war!/],/usr/local/jetty/jetty-distribution-7.2.0.v20101020/webapps/cargo-jetty-7-and-onwards-deployer-1.0.4.war
      java.lang.reflect.InvocationTargetException
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
      at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
      at org.eclipse.jetty.xml.XmlConfiguration.newObj(XmlConfiguration.java:639)
      at org.eclipse.jetty.xml.XmlConfiguration.configure(XmlConfiguration.java:262)
      at org.eclipse.jetty.xml.XmlConfiguration.configure(XmlConfiguration.java:196)
      at org.eclipse.jetty.webapp.JettyWebXmlConfiguration.configure(JettyWebXmlConfiguration.java:82)
      at org.eclipse.jetty.webapp.WebAppContext.configure(WebAppContext.java:470)
      at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1127)
      at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:577)
      at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:491)
      at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:55)
      at org.eclipse.jetty.deploy.bindings.StandardStarter.processBinding(StandardStarter.java:36)
      at org.eclipse.jetty.deploy.AppLifeCycle.runBindings(AppLifeCycle.java:180)
      at org.eclipse.jetty.deploy.DeploymentManager.requestAppGoal(DeploymentManager.java:497)
      at org.eclipse.jetty.deploy.DeploymentManager.addApp(DeploymentManager.java:135)
      at org.eclipse.jetty.deploy.providers.ScanningAppProvider.fileAdded(ScanningAppProvider.java:144)
      at org.eclipse.jetty.deploy.providers.ScanningAppProvider$1.fileAdded(ScanningAppProvider.java:57)
      at org.eclipse.jetty.util.Scanner.reportAddition(Scanner.java:436)
      at org.eclipse.jetty.util.Scanner.reportDifferences(Scanner.java:349)
      at org.eclipse.jetty.util.Scanner.scan(Scanner.java:306)
      at org.eclipse.jetty.util.Scanner.start(Scanner.java:242)
      at org.eclipse.jetty.deploy.providers.ScanningAppProvider.doStart(ScanningAppProvider.java:121)
      at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:55)
      at org.eclipse.jetty.deploy.DeploymentManager.startAppProvider(DeploymentManager.java:562)
      at org.eclipse.jetty.deploy.DeploymentManager.doStart(DeploymentManager.java:212)
      at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:55)
      at org.eclipse.jetty.server.Server.doStart(Server.java:226)
      at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:55)
      at org.eclipse.jetty.xml.XmlConfiguration$1.run(XmlConfiguration.java:1046)
      at java.security.AccessController.doPrivileged(Native Method)
      at org.eclipse.jetty.xml.XmlConfiguration.main(XmlConfiguration.java:983)
      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.eclipse.jetty.start.Main.invokeMain(Main.java:490)
      at org.eclipse.jetty.start.Main.start(Main.java:634)
      at org.eclipse.jetty.start.Main.parseCommandLine(Main.java:280)
      at org.eclipse.jetty.start.Main.main(Main.java:82)
      Caused by:
      java.lang.NoSuchMethodError: org.eclipse.jetty.webapp.WebAppClassLoader.getContext()Lorg/eclipse/jetty/server/handler/ContextHandler;
      at org.codehaus.cargo.deployer.jetty.DeployerServlet.<init>(DeployerServlet.java:87)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
      at java.lang.reflect.Constructor.newInstance(Constructor.java:513)
      at org.eclipse.jetty.xml.XmlConfiguration.newObj(XmlConfiguration.java:639)
      at org.eclipse.jetty.xml.XmlConfiguration.configure(XmlConfiguration.java:262)
      at org.eclipse.jetty.xml.XmlConfiguration.configure(XmlConfiguration.java:196)
      at org.eclipse.jetty.webapp.JettyWebXmlConfiguration.configure(JettyWebXmlConfiguration.java:82)
      at org.eclipse.jetty.webapp.WebAppContext.configure(WebAppContext.java:470)
      at org.eclipse.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1127)
      at org.eclipse.jetty.server.handler.ContextHandler.doStart(ContextHandler.java:577)
      at org.eclipse.jetty.webapp.WebAppContext.doStart(WebAppContext.java:491)
      at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:55)
      at org.eclipse.jetty.deploy.bindings.StandardStarter.processBinding(StandardStarter.java:36)
      at org.eclipse.jetty.deploy.AppLifeCycle.runBindings(AppLifeCycle.java:180)
      at org.eclipse.jetty.deploy.DeploymentManager.requestAppGoal(DeploymentManager.java:497)
      at org.eclipse.jetty.deploy.DeploymentManager.addApp(DeploymentManager.java:135)
      at org.eclipse.jetty.deploy.providers.ScanningAppProvider.fileAdded(ScanningAppProvider.java:144)
      at org.eclipse.jetty.deploy.providers.ScanningAppProvider$1.fileAdded(ScanningAppProvider.java:57)
      at org.eclipse.jetty.util.Scanner.reportAddition(Scanner.java:436)
      at org.eclipse.jetty.util.Scanner.reportDifferences(Scanner.java:349)
      at org.eclipse.jetty.util.Scanner.scan(Scanner.java:306)
      at org.eclipse.jetty.util.Scanner.start(Scanner.java:242)
      at org.eclipse.jetty.deploy.providers.ScanningAppProvider.doStart(ScanningAppProvider.java:121)
      at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:55)
      at org.eclipse.jetty.deploy.DeploymentManager.startAppProvider(DeploymentManager.java:562)
      at org.eclipse.jetty.deploy.DeploymentManager.doStart(DeploymentManager.java:212)
      at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:55)
      at org.eclipse.jetty.server.Server.doStart(Server.java:226)
      at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:55)
      at org.eclipse.jetty.xml.XmlConfiguration$1.run(XmlConfiguration.java:1046)
      at java.security.AccessController.doPrivileged(Native Method)
      at org.eclipse.jetty.xml.XmlConfiguration.main(XmlConfiguration.java:983)
      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.eclipse.jetty.start.Main.invokeMain(Main.java:490)
      at org.eclipse.jetty.start.Main.start(Main.java:634)
      at org.eclipse.jetty.start.Main.parseCommandLine(Main.java:280)
      at org.eclipse.jetty.start.Main.main(Main.java:82)
      2010-11-09 16:52:01.000:INFO::Deployment monitor /usr/local/jetty/jetty-distribution-7.2.0.v20101020/contexts at interval 5
      2010-11-09 16:52:01.000:INFO::Deployable added: /usr/local/jetty/jetty-distribution-7.2.0.v20101020/contexts/javadoc.xml
      2010-11-09 16:52:01.057:INFO::Started SelectChannelConnector@0.0.0.0:80
      

      5. Though seeing the error, I continued visiting http://www.hostname.com/cargo-jetty-deployer and see a page saying:

      HTTP ERROR: 503
      
      Problem accessing /cargo-jetty-deployer. Reason:
      
      Service Unavailable
      
      Powered by Jetty://
      

      6. I also tried visiting http://www.hostname.com/cargo-jetty-deployer/deploy?path=/sample and see the same page as above.
      7. Same thing happens visitng http://www.hostname.com/cargo-jetty-deployer/undeploy
      8. Having these results, I downloaded the cargo source from http://repo1.maven.org/maven2/org/codehaus/cargo/cargo-jetty-7-and-onwards-deployer/1.0.4/cargo-jetty-7-and-onwards-deployer-1.0.4-sources.jar and created a new war out from it by creating a new maven project and putting in all library dependencies in the pom.xml. I did not edit anything from the source code.
      9. Removed the old war file from JETTY_HOME/webapps
      10. I then put the new cargo-jetty-deployer in JETTY_HOME/webapps
      11. Start Jetty again and this time, no errors were logged.
      12. Now, going to http://www.hostname:com/cargo-jetty-deployer displays the page:

      Directory: /cargo-jetty-deployer/
      META-INF/ -1 bytes Nov 5, 2010 11:09:26 PM
      WEB-INF/ -1 bytes Nov 9, 2010 5:17:50 PM
      

      13. Click the both the 2 links, META-INF and WEB-INF displays the page:

      HTTP ERROR 404
      
      Problem accessing /cargo-jetty-deployer/WEB-INF/. Reason:
      
      Not Found
      
      Powered by Jetty://
      

      14. There's no activity in the jetty log.
      15. Now, going to http://www.hostname:com/cargo-jetty-deployer/deploy or /deploy?path=/sample or /undeploy displays the same 404 error message as above like:

      HTTP ERROR 404
      
      Problem accessing /cargo-jetty-deployer/deploy. Reason:
      
      Not Found
      
      Powered by Jetty://
      

      Any idea what's wrong?

        Gliffy Diagrams

          Issue Links

            Activity

            There are no comments yet on this issue.

              People

              • Assignee:
                savasalitokmen Savas Ali Tokmen
                Reporter:
                donsantillan Don Santillan
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: