0 Replies Latest reply on Feb 11, 2003 10:15 AM by Jorge Cardenas

    Exception when deploy an ear.

    Jorge Cardenas Newbie

      I'm working with the Interest example. Initially descriptors page are without a DOCTYPE and when i made deploy,it's made correctly. Nevertheless i included the DOCTYPE like this to continuation and i have problems.

      web.xml

      <?xml version="1.0" encoding="UTF-8"?>

      <!DOCTYPE web-app SYSTEM "file://localhost/usr/local/jboss-3.0.4/docs/dtd/web-app_2_3.dtd">

      <web-app>
      <!-- ### Servlets -->

      <servlet-name>InterestServlet</servlet-name>
      <servlet-class>org.jboss.docs.interest.InterestServlet</servlet-class>

      <servlet-mapping>
      <servlet-name>InterestServlet</servlet-name>
      <url-pattern>/InterestServlet</url-pattern>
      </servlet-mapping>

      <welcome-file-list>
      <welcome-file>home.html</welcome-file>
      </welcome-file-list>

      <!-- ### EJB References (java:comp/env/ejb) -->
      <ejb-ref>
      <ejb-ref-name>ejb/Interest</ejb-ref-name>
      <ejb-ref-type>Session</ejb-ref-type>
      org.jboss.docs.interest.InterestHome
      org.jboss.docs.interest.Interest
      </ejb-ref>

      </web-app>

      ejb-jar.xml
      <?xml version="1.0" encoding="UTF-8"?>

      <!DOCTYPE ejb-jar SYSTEM "file://localhost/usr/local/jboss-3.0.4/docs/dtd/ejb-jar_2_0.dtd">

      <ejb-jar>
      JBoss Interest Sample Application
      <display-name>Interest EJB</display-name>
      <enterprise-beans>

      <ejb-name>Interest</ejb-name>
      org.jboss.docs.interest.InterestHome
      org.jboss.docs.interest.Interest
      <ejb-class>org.jboss.docs.interest.InterestBean</ejb-class>
      <session-type>Stateless</session-type>
      <transaction-type>Bean</transaction-type>

      </enterprise-beans>
      </ejb-jar>

      and then i have the next Exception:

      2003-02-10 18:18:47,405 ERROR [org.jboss.deployment.scanner.URLDeploymentScanner] Failed to
      deploy: org.jboss.deployment.scanner.URLDeploymentScanner$DeployedURL@3e3e9993{ url=file:/
      usr/local/jboss-3.0.4/server/default/deploy/interest.ear, deployedLastModified=104491855600
      0 }
      org.jboss.deployment.DeploymentException: java.lang.NullPointerException; - nested throwabl
      e: (java.lang.NullPointerException)
      at org.jboss.metadata.XmlFileLoader.getDocument(XmlFileLoader.java:267)
      at org.jboss.metadata.XmlFileLoader.getDocumentFromURL(XmlFileLoader.java:226)
      at org.jboss.metadata.XmlFileLoader.load(XmlFileLoader.java:147)
      at org.jboss.ejb.EJBDeployer.create(EJBDeployer.java:321)
      at org.jboss.deployment.MainDeployer.create(MainDeployer.java:760)
      at org.jboss.deployment.MainDeployer.create(MainDeployer.java:752)
      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:620)
      at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:585)
      at sun.reflect.GeneratedMethodAccessor10.invoke(Unknown Source)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.jav
      a:25)
      at java.lang.reflect.Method.invoke(Method.java:324)
      at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher
      .java:284)
      at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
      at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)
      at $Proxy4.deploy(Unknown Source)
      at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.ja
      va:435)
      at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java
      :561)
      at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(Abst
      ractDeploymentScanner.java:212)
      at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(Abstra
      ctDeploymentScanner.java:225)
      at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(Abstrac
      tDeploymentScanner.java:202)
      Caused by: java.lang.NullPointerException
      at org.apache.crimson.parser.Parser2.parseInternal(Parser2.java:524)
      at org.apache.crimson.parser.Parser2.parse(Parser2.java:305)
      at org.apache.crimson.parser.XMLReaderImpl.parse(XMLReaderImpl.java:442)
      at org.apache.crimson.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:185)
      at javax.xml.parsers.DocumentBuilder.parse(DocumentBuilder.java:76)
      at org.jboss.metadata.XmlFileLoader.getDocument(XmlFileLoader.java:257)

      Can somebody help me?

      I need to made a local definition for this DOCTYPE.


      Thanks a lot!!

      Jk