3 Replies Latest reply on May 18, 2002 4:24 AM by Chris

    Missing URL Protocol Handler (JNDI) / jboss-3.0.0RC1_tomcat-

    Peter Neumcke Newbie

      After switching from jboss-3.0.0beta to jboss-3.0.0RC1_tomcat-4.0.3 the servlet that I try to deploy in JBoss throws an exception:
      MalformedURLException: missing protocol handler: jndi
      This occurs in the init() method of the servlet.

      The exact message is:

      [exec] javax.servlet.ServletException: Unable to determine servlet context URL.
      [exec] at org.apache.cocoon.servlet.CocoonServlet.init(CocoonServlet.java:262)
      [exec] at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:916)
      [exec] at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:808)
      [exec] at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3266)
      [exec] at org.apache.catalina.core.StandardContext.start(StandardContext.java:3395)
      [exec] at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:785)
      [exec] at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:454)
      [exec] at org.jboss.web.catalina.EmbeddedCatalinaServiceSX.createWebContext(EmbeddedCatalinaServiceSX.java:284)
      [exec] at org.jboss.web.catalina.EmbeddedCatalinaServiceSX.performDeploy(EmbeddedCatalinaServiceSX.java:204)
      [exec] at org.jboss.web.AbstractWebContainer.start(AbstractWebContainer.java:405)
      [exec] at org.jboss.deployment.MainDeployer.start(MainDeployer.java:665)
      [exec] at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:507)
      [exec] at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:470)
      [exec] at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
      [exec] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      [exec] at java.lang.reflect.Method.invoke(Method.java:324)
      [exec] at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
      [exec] at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:492)
      [exec] at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)
      [exec] at $Proxy4.deploy(Unknown Source)
      [exec] at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:350)
      [exec] at org.jboss.deployment.scanner.URLDeploymentScanner.scanDirectory(URLDeploymentScanner.java:530)
      [exec] at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:410)
      [exec] at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:202)
      [exec] at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(AbstractDeploymentScanner.java:191)
      [exec] 18:11:32,879 ERROR [Engine] ----- Root Cause -----
      [exec] java.net.MalformedURLException: unknown protocol: jndi
      [exec] at java.net.URL.(URL.java:586)
      [exec] at java.net.URL.(URL.java:476)
      [exec] at java.net.URL.(URL.java:425)
      [exec] at org.apache.cocoon.servlet.CocoonServlet.init(CocoonServlet.java:257)
      [exec] at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:916)
      [exec] at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:808)
      [exec] at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3266)
      [exec] at org.apache.catalina.core.StandardContext.start(StandardContext.java:3395)
      [exec] at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:785)
      [exec] at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:454)
      [exec] at org.jboss.web.catalina.EmbeddedCatalinaServiceSX.createWebContext(EmbeddedCatalinaServiceSX.java:284)
      [exec] at org.jboss.web.catalina.EmbeddedCatalinaServiceSX.performDeploy(EmbeddedCatalinaServiceSX.java:204)
      [exec] at org.jboss.web.AbstractWebContainer.start(AbstractWebContainer.java:405)
      [exec] at org.jboss.deployment.MainDeployer.start(MainDeployer.java:665)
      [exec] at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:507)
      [exec] at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:470)
      [exec] at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
      [exec] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
      [exec] at java.lang.reflect.Method.invoke(Method.java:324)
      [exec] at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
      [exec] at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:492)
      [exec] at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)
      [exec] at $Proxy4.deploy(Unknown Source)
      [exec] at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:350)
      [exec] at org.jboss.deployment.scanner.URLDeploymentScanner.scanDirectory(URLDeploymentScanner.java:530)
      [exec] at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:410)
      [exec] at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:202)
      [exec] at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(AbstractDeploymentScanner.java:191)


      The source code looks like this (CocoonServlet.java):

      try {
      if (path.indexOf(':') > 1) {
      this.servletContextURL = new URL(path);
      } else {
      this.servletContextURL = (new File(path)).toURL();
      }
      } catch (java.net.MalformedURLException me) {
      throw new ServletException("Unable to determine servlet context URL.", me);
      }