activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pga <payal_pa...@yahoo.co.in>
Subject Re: Integrate ActiveMQ with JBoss
Date Fri, 25 May 2007 15:23:11 GMT

Thanks for the valuable pointers.
It was really helpful.

Thanks

James.Strachan wrote:
> 
> On 5/24/07, pga <payal_palin@yahoo.co.in> wrote:
>>
>> After Integrating ActiveMQ4.1.1 with JBoss4.0.4, when i try starting the
>> JBoss Server, I get the following exception:
>>
>> 11:04:57,440 ERROR [BatchSchedulerServlet] Error occurred
>>
>> org.springframework.beans.factory.access.BootstrapException: Unable to
>> initialize group definition. Group resource name
>> [classpath*:testbeanRefFactory.xml], factory key [beanRefFactory]; nested
>> exception is org.springframework.beans.factory.BeanCreationException:
>> Error
>> creating bean with name 'beanRefFactory' defined in URL
>> [jar:file:/D:/jboss-4.0.4/server/default/tmp/deploy/tmp54062subscription-3.1.ear-contents/subscription-core-3.1.jar!/testbeanRefFactory.xml]:
>> Instantiation of bean failed; nested exception is
>> org.springframework.beans.BeanInst
>>
>> Caused by:
>>
>> org.springframework.beans.factory.BeanCreationException: Error creating
>> bean
>> with name 'beanRefFactory' defined in URL
>> [jar:file:/D:/jboss-4.0.4/server/default/tmp/deploy/tmp54062subscription-3.1.ear-contents/subscription-core-3.1.jar!/testbeanRefFactory.xml]:
>> Instantiation of bean failed; nested exception is
>> org.springframework.beans.BeanInstantiationException: Could not
>> instantiate
>> bean class
>> [org.springframework.context.support.ClassPathXmlApplicationContext]:
>> Constructor threw exception; nested exception is
>> org.springframework.beans.factory.B
>>
>> Caused by:
>>
>> org.springframework.beans.BeanInstantiationException: Could not
>> instantiate
>> bean class
>> [org.springframework.context.support.ClassPathXmlApplicationContext]:
>> Constructor threw exception; nested exception is
>> org.springframework.beans.factory.BeanCreationException: Error creating
>> bean
>> with name 'sessionFactory' defined in class path resource
>> [applicationContext.xml]: Invocation of init method failed; nested
>> exception
>> is java.lang.ClassCastException: java.util.HashSet
>>
>> Caused by:
>>
>> org.springframework.beans.factory.BeanCreationException: Error creating
>> bean
>> with name 'sessionFactory' defined in class path resource
>> [applicationContext.xml]: Invocation of init method failed; nested
>> exception
>> is java.lang.ClassCastException: java.util.HashSet
>>
>> Caused by:
>>
>> java.lang.ClassCastException: java.util.HashSet
>>         at
>> org.hibernate.util.PropertiesHelper.resolvePlaceHolders(PropertiesHelper.java:88)
>>         at
>> org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1173)
>>         at
>> org.springframework.orm.hibernate3.LocalSessionFactoryBean.newSessionFactory(LocalSessionFactoryBean.java:825)
>>         at
>> org.springframework.orm.hibernate3.LocalSessionFactoryBean.afterPropertiesSet(LocalSessionFactoryBean.java:751)
>>         at
>> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1062)
>>         at
>> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1029)
>>         at
>> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:420)
>>         at
>> org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:245)
>>         at
>> org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:141)
>>         at
>> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:242)
>>         at
>> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:156)
>>         at
>> org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:287)
>>         at
>> org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:348)
>>         at
>> org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:92)
>>         at
>> org.springframework.context.support.ClassPathXmlApplicationContext.<init>(ClassPathXmlApplicationContext.java:77)
>>         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:494)
>>         at
>> org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:82)
>>         at
>> org.springframework.beans.factory.support.SimpleInstantiationStrategy.instantiate(SimpleInstantiationStrategy.java:78)
>>         at
>> org.springframework.beans.factory.support.ConstructorResolver.autowireConstructor(ConstructorResolver.java:156)
>>         at
>> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.autowireConstructor(AbstractAutowireCapableBeanFactory.java:683)
>>         at
>> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:621)
>>         at
>> org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:380)
>>         at
>> org.springframework.beans.factory.support.AbstractBeanFactory$1.getObject(AbstractBeanFactory.java:245)
>>         at
>> org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:141)
>>         at
>> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:242)
>>         at
>> org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:156)
>>         at
>> org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:290)
>>         at
>> org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:348)
>>         at
>> org.springframework.context.access.ContextSingletonBeanFactoryLocator.initializeDefinition(ContextSingletonBeanFactoryLocator.java:136)
>>         at
>> org.springframework.beans.factory.access.SingletonBeanFactoryLocator.useBeanFactory(SingletonBeanFactoryLocator.java:386)
>>         at
>> com.tomtom.subs.common.ServiceLocator.getContext(ServiceLocator.java:106)
>>         at
>> com.tomtom.subs.common.ServiceLocator.getConfigXmlService(ServiceLocator.java:165)
>>         at
>> com.tomtom.subs.common.ConfigReader.getXsdMap(ConfigReader.java:82)
>>         at
>> com.tomtom.subs.common.ConfigHelper.<init>(ConfigHelper.java:96)
>>         at
>> com.tomtom.subs.common.ConfigHelper.getInstance(ConfigHelper.java:129)
>>         at
>> com.tomtom.subs.intershop.ISRequestSubscriber.<init>(ISRequestSubscriber.java:30)
>>         at
>> com.tomtom.subs.common.BatchSchedulerServlet.init(BatchSchedulerServlet.java:31)
>>         at javax.servlet.GenericServlet.init(GenericServlet.java:211)
>>         at
>> org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1105)
>>         at
>> org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:932)
>>         at
>> org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3917)
>>         at
>> org.apache.catalina.core.StandardContext.start(StandardContext.java:4201)
>>         at
>> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
>>         at
>> org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
>>         at
>> org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
>>         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.apache.commons.modeler.BaseModelMBean.invoke(BaseModelMBean.java:503)
>>         at
>> org.jboss.mx.server.RawDynamicInvoker.invoke(RawDynamicInvoker.java:164)
>>        at
>> org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
>>         at
>> org.apache.catalina.core.StandardContext.init(StandardContext.java:5116)
>>         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.apache.commons.modeler.BaseModelMBean.invoke(BaseModelMBean.java:503)
>>         at
>> org.jboss.mx.server.RawDynamicInvoker.invoke(RawDynamicInvoker.java:164)
>>         at
>> org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:659)
>>         at
>> org.jboss.web.tomcat.tc5.TomcatDeployer.performDeployInternal(TomcatDeployer.java:297)
>>         at
>> org.jboss.web.tomcat.tc5.TomcatDeployer.performDeploy(TomcatDeployer.java:103)
>>         at
>> org.jboss.web.AbstractWebDeployer.start(AbstractWebDeployer.java:371)
>>         at org.jboss.web.WebModule.startModule(WebModule.java:83)
>>         at org.jboss.web.WebModule.startService(WebModule.java:61)
>>         at
>> org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289)
>>         at
>> org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245)
>>         at sun.reflect.GeneratedMethodAccessor2.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: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(DelegatingMethodAccessorImpl.java:25)
>>
>>         at java.lang.reflect.Method.invoke(Method.java:585)
>>
>>         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 $Proxy30.start(Unknown Source)
>>
>>         at
>> org.jboss.web.AbstractWebContainer.start(AbstractWebContainer.java:466)
>>
>>         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: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.ws.server.WebServiceDeployer.start(WebServiceDeployer.java:117)
>>
>>         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 $Proxy31.start(Unknown Source)
>>
>>         at
>> org.jboss.deployment.MainDeployer.start(MainDeployer.java:1007)
>>
>>         at org.jboss.deployment.MainDeployer.start(MainDeployer.java:997)
>>
>>         at
>> org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:808)
>>
>>         at
>> org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:771)
>>
>>         at sun.reflect.GeneratedMethodAccessor50.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: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 $Proxy8.deploy(Unknown Source)
>>
>>         at
>> org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:421)
>>
>>         at
>> org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:634)
>>
>>         at
>> org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:263)
>>
>>         at
>> org.jboss.deployment.scanner.AbstractDeploymentScanner.startService(AbstractDeploymentScanner.java:336)
>>
>>         at
>> org.jboss.system.ServiceMBeanSupport.jbossInternalStart(ServiceMBeanSupport.java:289)
>>
>>         at
>> org.jboss.system.ServiceMBeanSupport.jbossInternalLifecycle(ServiceMBeanSupport.java:245)
>>
>>         at sun.reflect.GeneratedMethodAccessor2.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: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(DelegatingMethodAccessorImpl.java:25)
>>
>>         at java.lang.reflect.Method.invoke(Method.java:585)
>>
>>         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 $Proxy4.start(Unknown Source)
>>
>>         at org.jboss.deployment.SARDeployer.start(SARDeployer.java:302)
>>
>>         at
>> org.jboss.deployment.MainDeployer.start(MainDeployer.java:1007)
>>
>>         at
>> org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:808)
>>
>>         at
>> org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:771)
>>
>>         at
>> org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:755)
>>
>>         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: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 $Proxy5.deploy(Unknown Source)
>>
>>         at
>> org.jboss.system.server.ServerImpl.doStart(ServerImpl.java:482)
>>
>>         at org.jboss.system.server.ServerImpl.start(ServerImpl.java:362)
>>
>>         at org.jboss.Main.boot(Main.java:200)
>>
>>         at org.jboss.Main$1.run(Main.java:464)
>>
>>         at java.lang.Thread.run(Thread.java:595)
>>
>>
>>
>>
>>
>> My BatchScheduler servlet is configure to be invoked on JBoss start up.
>> Befor  integrating the ActiveMQ, it used to work fine.
>> Am I missing something?
> 
> I think this is caused by ActiveMQ putting an object into the System
> properties that hibernate doens't like (for the file locking in the
> journal). Options to fix this include
> 
> * run the broker in a separate jvm
> * use 4.2 or later which has this issue fixed
> * use pure JDBC rather than the journal
> 
> There could be some other work arounds too; IIRC there was some way to
> disable the use of system properties with the journal but can't
> remember right now; you might wanna noodle the activeio code
> 
> -- 
> James
> -------
> http://macstrac.blogspot.com/
> 
> 

-- 
View this message in context: http://www.nabble.com/Integrate-ActiveMQ-with-JBoss-tf3809418s2354.html#a10805126
Sent from the ActiveMQ - Dev mailing list archive at Nabble.com.


Mime
View raw message