JBoss 4.2.2 GA throws an exception when I deploy

Discussions

EJB programming & troubleshooting: JBoss 4.2.2 GA throws an exception when I deploy

  1. Hi, I'm experiencing a strange problem. I have been using JBoss 4.0.5 GA so far, now I have upgraded to 4.2.2 GA. In my project there is a package contianing entity beans - when I deploy the package and start jboss, everything is fine. But if I deploy the package AFTER jboss is started, or I simply redeploy the package, I get the error attached below. What's strange is that the file causing the error is /jboss/server/default/conf/standardjbosscmp-jdbc.xml, which is shipped with jboss and I haven't changed in any way. Also, I tryed to replace it with the one of the 4.0.5 version, but same result. Any idea why this is happening? Thank Antonio 11:45:52,859 WARN [ServiceController] Problem starting service jboss.j2ee:service=EjbModule,module=010-BannerEngineCore.jar org.jboss.deployment.DeploymentException: Invalid XML: file=file:/C:/DevTools/AppServers/jboss-4.2.2.GA/server/default/conf/standardjbosscmp-jdbc.xml; - nested throwable: (org.xml.sax.SAXParseException: The content of element type "defaults" must match "(datasource?,datasource-mapping?,create-table?,alter-table?,remove-table?,post-table-create?,read-only?,read-time-out?,row-locking?,pk-constraint?,fk-constraint?,preferred-relation-mapping?,read-ahead?,list-cache-max?,clean-read-ahead-on-load?,fetch-size?,unknown-pk?,entity-command?,ql-compiler?)".) at org.jboss.metadata.XmlFileLoader.getDocument(XmlFileLoader.java:331) at org.jboss.metadata.XmlFileLoader.getDocument(XmlFileLoader.java:272) at org.jboss.metadata.XmlFileLoader.getDocumentFromURL(XmlFileLoader.java:244) at org.jboss.metadata.XmlFileLoader.getDocument(XmlFileLoader.java:228) at org.jboss.ejb.plugins.cmp.jdbc.metadata.JDBCXmlFileLoader.load(JDBCXmlFileLoader.java:78) at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.loadJDBCEntityMetaData(JDBCStoreManager.java:736) at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.initStoreManager(JDBCStoreManager.java:424) at org.jboss.ejb.plugins.cmp.jdbc.JDBCStoreManager.start(JDBCStoreManager.java:368) at org.jboss.ejb.plugins.CMPPersistenceManager.start(CMPPersistenceManager.java:172) at org.jboss.ejb.EjbModule.startService(EjbModule.java:414) at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289) at org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245) at sun.reflect.GeneratedMethodAccessor148.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.server.Invocation.invoke(Invocation.java:86) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978) at $Proxy0.start(Unknown Source) at org.jboss.system.ServiceController.start(ServiceController.java:417) at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.server.Invocation.invoke(Invocation.java:86) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210) at $Proxy31.start(Unknown Source) at org.jboss.ejb.EJBDeployer.start(EJBDeployer.java:662) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133) at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142) at org.jboss.mx.interceptor.DynamicInterceptor.invoke(DynamicInterceptor.java:97) at org.jboss.system.InterceptorServiceMBeanSupport.invokeNext(InterceptorServiceMBeanSupport.java:238) at org.jboss.wsf.container.jboss42.DeployerInterceptor.start(DeployerInterceptor.java:87) at org.jboss.deployment.SubDeployerInterceptorSupport$XMBeanInterceptor.start(SubDeployerInterceptorSupport.java:188) at org.jboss.deployment.SubDeployerInterceptor.invoke(SubDeployerInterceptor.java:95) at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210) at $Proxy32.start(Unknown Source) at org.jboss.deployment.MainDeployer.start(MainDeployer.java:1025) at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:819) at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:782) at sun.reflect.GeneratedMethodAccessor20.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:155) at org.jboss.mx.server.Invocation.dispatch(Invocation.java:94) at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:133) at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:142) at org.jboss.mx.server.Invocation.invoke(Invocation.java:88) at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:264) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659) at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:210) at $Proxy9.deploy(Unknown Source) at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:421) at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:610) at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:263) at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:274) at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(AbstractDeploymentScanner.java:225) Caused by: org.xml.sax.SAXParseException: The content of element type "defaults" must match "(datasource?,datasource-mapping?,create-table?,alter-table?,remove-table?,post-table-create?,read-only?,read-time-out?,row-locking?,pk-constraint?,fk-constraint?,preferred-relation-mapping?,read-ahead?,list-cache-max?,clean-read-ahead-on-load?,fetch-size?,unknown-pk?,entity-command?,ql-compiler?)". at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source) at org.apache.xerces.util.ErrorHandlerWrapper.error(Unknown Source) at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source) at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source) at org.apache.xerces.impl.dtd.XMLDTDValidator.handleEndElement(Unknown Source) at org.apache.xerces.impl.dtd.XMLDTDValidator.endElement(Unknown Source) at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanEndElement(Unknown Source) at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source) at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source) at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) at org.apache.xerces.parsers.XMLParser.parse(Unknown Source) at org.apache.xerces.parsers.DOMParser.parse(Unknown Source) at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source) at org.jboss.metadata.XmlFileLoader.getDocument(XmlFileLoader.java:328) ... 73 more 11:45:52,859 INFO [EJBDeployer] Deployed: file:/C:/DevTools/AppServers/jboss-4.2.2.GA/server/default/deploy/010-BannerEngineCore.jar/ 11:45:53,125 ERROR [URLDeploymentScanner] Incomplete Deployment listing: --- MBeans waiting for other MBeans --- ObjectName: jboss.j2ee:service=EjbModule,module=010-BannerEngineCore.jar State: FAILED Reason: org.jboss.deployment.DeploymentException: Invalid XML: file=file:/C:/DevTools/AppServers/jboss-4.2.2.GA/server/default/conf/standardjbosscmp-jdbc.xml; - nested throwable: (org.xml.sax.SAXParseException: The content of element type "defaults" must match "(datasource?,datasource-mapping?,create-table?,alter-table?,remove-table?,post-table-create?,read-only?,read-time-out?,row-locking?,pk-constraint?,fk-constraint?,preferred-relation-mapping?,read-ahead?,list-cache-max?,clean-read-ahead-on-load?,fetch-size?,unknown-pk?,entity-command?,ql-compiler?)".) --- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM --- ObjectName: jboss.j2ee:service=EjbModule,module=010-BannerEngineCore.jar State: FAILED Reason: org.jboss.deployment.DeploymentException: Invalid XML: file=file:/C:/DevTools/AppServers/jboss-4.2.2.GA/server/default/conf/standardjbosscmp-jdbc.xml; - nested throwable: (org.xml.sax.SAXParseException: The content of element type "defaults" must match "(datasource?,datasource-mapping?,create-table?,alter-table?,remove-table?,post-table-create?,read-only?,read-time-out?,row-locking?,pk-constraint?,fk-constraint?,preferred-relation-mapping?,read-ahead?,list-cache-max?,clean-read-ahead-on-load?,fetch-size?,unknown-pk?,entity-command?,ql-compiler?)".)
  2. Such exceptions occur sometimes due to classpath issues, check that if you're certain the config file is valid. /S