6 Replies Latest reply on Apr 27, 2006 6:59 AM by Mark Little

    Standalone JBoss Messaging/ESB

    Arvinder Singh Novice



      FYI, I'm running an MBean inside a stripped/slimmed down jboss messaging server.
      The MBean boots a standalone MC Bootstrapper class within its startService
      method.

      There seems to be a mismatch of library versions which leads to java.lang.NoSuchMethodError
      exceptions.

      I am using:

      - microcontainer-1.0.2 (all the jars from lib packaged inside my sar)
      - jboss-4.0.3SP1
      - jdk1.5.0_02

      Stack trace:

      F:\projects\jboss\svn\jboss-4.0.3SP1\bin>run -c esb
      ===============================================================================
      .
       JBoss Bootstrap Environment
      .
       JBOSS_HOME: F:\projects\jboss\svn\jboss-4.0.3SP1\bin\\..
      .
       JAVA: C:\java\jdk\jdk1.5.0_02\bin\java
      .
       JAVA_OPTS: -Dprogram.name=run.bat -Xms128m -Xmx512m
      .
       CLASSPATH: C:\java\jdk\jdk1.5.0_02\lib\tools.jar;F:\projects\jboss\svn\jboss-4.0.3SP1\bin\\run.jar
      .
      ===============================================================================
      .
      10:38:43,674 INFO [Server] Starting JBoss (MX MicroKernel)...
      10:38:43,674 INFO [Server] Release ID: JBoss [Zion] 4.0.3SP1 (build: CVSTag=JBoss_4_0_3_SP1 date=200510231054)
      10:38:43,684 INFO [Server] Home Dir: F:\projects\jboss\svn\jboss-4.0.3SP1
      10:38:43,684 INFO [Server] Home URL: file:/F:/projects/jboss/svn/jboss-4.0.3SP1/
      10:38:43,684 INFO [Server] Patch URL: null
      10:38:43,684 INFO [Server] Server Name: esb
      10:38:43,684 INFO [Server] Server Home Dir: F:\projects\jboss\svn\jboss-4.0.3SP1\server\esb
      10:38:43,684 INFO [Server] Server Home URL: file:/F:/projects/jboss/svn/jboss-4.0.3SP1/server/esb/
      10:38:43,684 INFO [Server] Server Temp Dir: F:\projects\jboss\svn\jboss-4.0.3SP1\server\esb\tmp
      10:38:43,684 INFO [Server] Root Deployment Filename: jboss-service.xml
      10:38:44,323 INFO [ServerInfo] Java version: 1.5.0_02,Sun Microsystems Inc.
      10:38:44,333 INFO [ServerInfo] Java VM: Java HotSpot(TM) Client VM 1.5.0_02-b09,Sun Microsystems Inc.
      10:38:44,333 INFO [ServerInfo] OS-System: Windows XP 5.1,x86
      10:38:44,973 INFO [Server] Core system initialized
      10:38:47,202 INFO [Log4jService$URLWatchTimerTask] Configuring from URL: resource:log4j.xml
      10:38:47,961 INFO [NamingService] Started jndi bootstrap jnpPort=1099, rmiPort=1098, backlog=50, bindAddress=/0.0.0.0, Client SocketFactory
      =null, Server SocketFactory=org.jboss.net.sockets.DefaultSocketFactory@ad093076
      10:39:55,578 INFO [Embedded] Catalina naming disabled
      10:39:56,170 INFO [Http11Protocol] Initializing Coyote HTTP/1.1 on http-0.0.0.0-8080
      10:39:56,170 INFO [Catalina] Initialization processed in 471 ms
      10:39:56,180 INFO [StandardService] Starting service jboss.web
      10:39:56,180 INFO [StandardEngine] Starting Servlet Engine: Apache Tomcat/5.5
      10:39:56,240 INFO [StandardHost] XML validation disabled
      10:39:56,260 INFO [Catalina] Server startup in 90 ms
      10:39:56,461 INFO [TomcatDeployer] deploy, ctxPath=/, warUrl=.../deploy/jbossweb-tomcat55.sar/ROOT.war/
      10:39:58,706 INFO [WebappLoader] Dual registration of jndi stream handler: factory already defined
      10:40:08,672 INFO [TomcatDeployer] deploy, ctxPath=/web-console, warUrl=.../deploy/management/console-mgr.sar/web-console.war/
      10:40:11,720 INFO [[/web-console]] J2EEFolder: Failed to init plugin, bsh/Interpreter
      10:40:11,890 INFO [[/web-console]] SystemFolder: Failed to init plugin, bsh/Interpreter
      10:40:15,489 INFO [RARDeployment] Required license terms exist, view META-INF/ra.xml in .../deploy/jboss-local-jdbc.rar
      10:40:17,033 INFO [ConnectionFactoryBindingService] Bound ConnectionManager 'jboss.jca:service=DataSourceBinding,name=DefaultDS' to JNDI na
      me 'java:DefaultDS'
      10:40:17,214 WARN [JDBCPersistenceManager]
      
      Warning! Connection transaction isolation should be READ_COMMITTED, but it is currently NONE.
       Using an isolation level less strict than READ_COMMITTED may lead to data consistency problems.
       Using an isolation level more strict than READ_COMMITTED may lead to deadlock.
      
      10:40:23,360 INFO [ServerPeer] JMS ServerPeer [server.0] started, connection failure checking active, lease period 20000 ms
      10:40:23,380 INFO [ConnectionFactory] [/ConnectionFactory, /XAConnectionFactory, java:/ConnectionFactory, java:/XAConnectionFactory] deploy
      ed
      10:40:23,450 INFO [Topic] Topic[/topic/testTopic] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      10:40:23,460 INFO [Topic] Topic[/topic/securedTopic] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      10:40:23,460 INFO [Topic] Topic[/topic/testDurableTopic] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      10:40:23,590 INFO [Queue] Queue[/queue/testQueue] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      10:40:23,600 INFO [Queue] Queue[/queue/DLQ] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      10:40:23,600 INFO [Queue] Queue[/queue/A] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      10:40:23,600 INFO [Queue] Queue[/queue/B] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      10:40:23,610 INFO [Queue] Queue[/queue/C] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      10:40:23,610 INFO [Queue] Queue[/queue/D] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      10:40:23,610 INFO [Queue] Queue[/queue/ex] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      10:40:23,610 INFO [Topic] Topic[/topic/openTopic] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      10:40:23,690 INFO [TomcatDeployer] deploy, ctxPath=/jmx-console, warUrl=.../deploy/jmx-console.war/
      10:40:27,971 INFO [Http11Protocol] Starting Coyote HTTP/1.1 on http-0.0.0.0-8080
      10:40:28,011 INFO [Server] JBoss (MX MicroKernel) [4.0.3SP1 (build: CVSTag=JBoss_4_0_3_SP1 date=200510231054)] Started in 1m:44s:327ms
      11:26:54,997 INFO [JBossESBServiceMBean] Starting JBossESB.
      11:26:55,268 WARN [ServiceController] Problem starting service jboss.esb:service=JBossESBServiceMBean
      java.lang.NoSuchMethodError: org.jboss.xb.binding.sunday.unmarshalling.TypeBinding.setHandler(Lorg/jboss/xb/binding/sunday/unmarshalling/Par
      ticleHandler;)V
       at org.jboss.kernel.plugins.deployment.xml.BeanSchemaBinding.init(BeanSchemaBinding.java:257)
       at org.jboss.kernel.plugins.deployment.xml.BeanSchemaBinding.getSchemaBinding(BeanSchemaBinding.java:243)
       at org.jboss.kernel.plugins.deployment.xml.BeanXMLDeployer.<init>(BeanXMLDeployer.java:49)
       at org.jboss.soa.esbcore.deploy.bootstrap.container.JBossESBKernel.bootstrap(JBossESBKernel.java:132)
       at org.jboss.kernel.plugins.bootstrap.AbstractBootstrap.run(AbstractBootstrap.java:91)
       at org.jboss.soa.esbcore.deploy.bootstrap.container.JBossESBServiceMBean.startService(JBossESBServiceMBean.java:57)
       at org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:274)
       at org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:181)
       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:585)
       at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:141)
       at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
       at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:118)
       at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
       at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:127)
       at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
       at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:245)
       at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:644)
       at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:960)
       at $Proxy0.start(Unknown Source)
       at org.jboss.system.ServiceController.start(ServiceController.java:428)
       at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:585)
       at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:141)
       at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
       at org.jboss.mx.server.Invocation.invoke(Invocation.java:72)
       at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:245)
       at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:644)
       at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:176)
       at $Proxy4.start(Unknown Source)
       at org.jboss.deployment.SARDeployer.start(SARDeployer.java:285)
       at org.jboss.deployment.MainDeployer.start(MainDeployer.java:989)
       at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:790)
       at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:753)
       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:585)
       at org.jboss.mx.interceptor.ReflectedDispatcher.invoke(ReflectedDispatcher.java:141)
       at org.jboss.mx.server.Invocation.dispatch(Invocation.java:80)
       at org.jboss.mx.interceptor.AbstractInterceptor.invoke(AbstractInterceptor.java:118)
       at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
       at org.jboss.mx.interceptor.ModelMBeanOperationInterceptor.invoke(ModelMBeanOperationInterceptor.java:127)
       at org.jboss.mx.server.Invocation.invoke(Invocation.java:74)
       at org.jboss.mx.server.AbstractMBeanInvoker.invoke(AbstractMBeanInvoker.java:245)
       at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:644)
       at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:176)
       at $Proxy7.deploy(Unknown Source)
       at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:319)
       at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:507)
       at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:192)
       at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:203)
       at org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(AbstractDeploymentScanner.java:182)
      11:26:55,278 ERROR [URLDeploymentScanner] Incomplete Deployment listing:
      
      --- MBeans waiting for other MBeans ---
      ObjectName: jboss.esb:service=JBossESBServiceMBean
       State: FAILED
       Reason: java.lang.NoSuchMethodError: org.jboss.xb.binding.sunday.unmarshalling.TypeBinding.setHandler(Lorg/jboss/xb/binding/sunday/unmarsh
      alling/ParticleHandler;)V
      
      --- MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM ---
      ObjectName: jboss.esb:service=JBossESBServiceMBean
       State: FAILED
       Reason: java.lang.NoSuchMethodError: org.jboss.xb.binding.sunday.unmarshalling.TypeBinding.setHandler(Lorg/jboss/xb/binding/sunday/unmarsh
      alling/ParticleHandler;)V
      


      I *think* this points to a version mismatch, related to jbossxb. Inside jboss-4.0.3SP1\lib\jboss-common.jar are jbossxb
      classes that are loaded first, before my sar is brought up.

      With MC 1.0.1 Release, this does not occur. So for now I will have to use this version. But since I am not using the MC api in detail, it should be ok to move over.

      Here is startup using Mc 1.0.1
      F:\projects\jboss\svn\jboss-4.0.3SP1\bin>run -c esb
      ===============================================================================
      .
       JBoss Bootstrap Environment
      .
       JBOSS_HOME: F:\projects\jboss\svn\jboss-4.0.3SP1\bin\\..
      .
       JAVA: C:\java\jdk\jdk1.5.0_02\bin\java
      .
       JAVA_OPTS: -Dprogram.name=run.bat -Xms128m -Xmx512m
      .
       CLASSPATH: C:\java\jdk\jdk1.5.0_02\lib\tools.jar;F:\projects\jboss\svn\jboss-4.0.3SP1\bin\\run.jar
      .
      ===============================================================================
      .
      11:41:30,763 INFO [Server] Starting JBoss (MX MicroKernel)...
      11:41:30,763 INFO [Server] Release ID: JBoss [Zion] 4.0.3SP1 (build: CVSTag=JBoss_4_0_3_SP1 date=200510231054)
      11:41:30,773 INFO [Server] Home Dir: F:\projects\jboss\svn\jboss-4.0.3SP1
      11:41:30,773 INFO [Server] Home URL: file:/F:/projects/jboss/svn/jboss-4.0.3SP1/
      11:41:30,773 INFO [Server] Patch URL: null
      11:41:30,773 INFO [Server] Server Name: esb
      11:41:30,773 INFO [Server] Server Home Dir: F:\projects\jboss\svn\jboss-4.0.3SP1\server\esb
      11:41:30,773 INFO [Server] Server Home URL: file:/F:/projects/jboss/svn/jboss-4.0.3SP1/server/esb/
      11:41:30,773 INFO [Server] Server Temp Dir: F:\projects\jboss\svn\jboss-4.0.3SP1\server\esb\tmp
      11:41:30,783 INFO [Server] Root Deployment Filename: jboss-service.xml
      11:41:31,284 INFO [ServerInfo] Java version: 1.5.0_02,Sun Microsystems Inc.
      11:41:31,294 INFO [ServerInfo] Java VM: Java HotSpot(TM) Client VM 1.5.0_02-b09,Sun Microsystems Inc.
      11:41:31,294 INFO [ServerInfo] OS-System: Windows XP 5.1,x86
      11:41:31,794 INFO [Server] Core system initialized
      11:41:33,417 INFO [Log4jService$URLWatchTimerTask] Configuring from URL: resource:log4j.xml
      11:41:34,889 INFO [NamingService] Started jndi bootstrap jnpPort=1099, rmiPort=1098, backlog=50, bindAddress=/0.0.0.0, Client SocketFactory
      =null, Server SocketFactory=org.jboss.net.sockets.DefaultSocketFactory@ad093076
      11:42:55,177 INFO [Embedded] Catalina naming disabled
      11:42:55,748 INFO [Http11Protocol] Initializing Coyote HTTP/1.1 on http-0.0.0.0-8080
      11:42:55,748 INFO [Catalina] Initialization processed in 481 ms
      11:42:55,748 INFO [StandardService] Starting service jboss.web
      11:42:55,758 INFO [StandardEngine] Starting Servlet Engine: Apache Tomcat/5.5
      11:42:55,808 INFO [StandardHost] XML validation disabled
      11:42:55,828 INFO [Catalina] Server startup in 80 ms
      11:42:56,008 INFO [TomcatDeployer] deploy, ctxPath=/, warUrl=.../deploy/jbossweb-tomcat55.sar/ROOT.war/
      11:42:58,291 INFO [WebappLoader] Dual registration of jndi stream handler: factory already defined
      11:43:04,530 INFO [TomcatDeployer] deploy, ctxPath=/web-console, warUrl=.../deploy/management/console-mgr.sar/web-console.war/
      11:43:09,127 INFO [[/web-console]] J2EEFolder: Failed to init plugin, bsh/Interpreter
      11:43:09,217 INFO [[/web-console]] SystemFolder: Failed to init plugin, bsh/Interpreter
      11:43:11,070 INFO [RARDeployment] Required license terms exist, view META-INF/ra.xml in .../deploy/jboss-local-jdbc.rar
      11:43:11,991 INFO [ConnectionFactoryBindingService] Bound ConnectionManager 'jboss.jca:service=DataSourceBinding,name=DefaultDS' to JNDI na
      me 'java:DefaultDS'
      11:43:12,342 WARN [JDBCPersistenceManager]
      
      Warning! Connection transaction isolation should be READ_COMMITTED, but it is currently NONE.
       Using an isolation level less strict than READ_COMMITTED may lead to data consistency problems.
       Using an isolation level more strict than READ_COMMITTED may lead to deadlock.
      
      11:43:18,601 INFO [ServerPeer] JMS ServerPeer [server.0] started, connection failure checking active, lease period 20000 ms
      11:43:18,621 INFO [ConnectionFactory] [/ConnectionFactory, /XAConnectionFactory, java:/ConnectionFactory, java:/XAConnectionFactory] deploy
      ed
      11:43:18,711 INFO [Topic] Topic[/topic/testTopic] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      11:43:18,711 INFO [Topic] Topic[/topic/securedTopic] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      11:43:18,711 INFO [Topic] Topic[/topic/testDurableTopic] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      11:43:18,841 INFO [Queue] Queue[/queue/testQueue] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      11:43:18,851 INFO [Queue] Queue[/queue/DLQ] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      11:43:18,851 INFO [Queue] Queue[/queue/A] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      11:43:18,851 INFO [Queue] Queue[/queue/B] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      11:43:18,861 INFO [Queue] Queue[/queue/C] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      11:43:18,871 INFO [Queue] Queue[/queue/D] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      11:43:18,871 INFO [Queue] Queue[/queue/ex] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      11:43:18,892 INFO [Topic] Topic[/topic/openTopic] started, fullSize=75000, pageSize=2000, downCacheSize=1000
      11:43:19,022 INFO [TomcatDeployer] deploy, ctxPath=/jmx-console, warUrl=.../deploy/jmx-console.war/
      11:43:23,028 INFO [Http11Protocol] Starting Coyote HTTP/1.1 on http-0.0.0.0-8080
      11:43:23,048 INFO [Server] JBoss (MX MicroKernel) [4.0.3SP1 (build: CVSTag=JBoss_4_0_3_SP1 date=200510231054)] Started in 1m:52s:265ms
      11:44:56,154 INFO [JBossESBServiceMBean] Starting JBossESB.
      11:44:56,585 INFO [JBossESBKernel] Deploying file:/F:/projects/jboss/svn/jboss-4.0.3SP1/server/esb/conf/jboss-esb-core.xml
      11:44:56,625 INFO [JBossESBKernel] Deployed file:/F:/projects/jboss/svn/jboss-4.0.3SP1/server/esb/conf/jboss-esb-core.xml
      11:44:56,625 INFO [JBossESBKernel] Deploying file:/F:/projects/jboss/svn/jboss-4.0.3SP1/server/esb/conf/jboss-esb-services.xml
      11:44:56,655 INFO [JBossESBKernel] Deployed file:/F:/projects/jboss/svn/jboss-4.0.3SP1/server/esb/conf/jboss-esb-services.xml