You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by jcarreira <jc...@gmail.com> on 2006/07/27 20:53:05 UTC

ActiveMQ with Spring 2.0?

Anyone using ActiveMQ 4.0.1 with Spring 2.0 ?

I've found that the XBean configuration isn't usable, since it apparently
depends on an old version of Spring. Here's the error:

org.springframework.beans.factory.BeanCreationException: Error creating bean
with name 'broker' defined in class path resource [jmsContext.xml]:
Invocation of init method failed; nested exception is
java.lang.NoClassDefFoundError:
org/springframework/beans/factory/xml/DefaultXmlBeanDefinitionParser
Caused by: 
java.lang.NoClassDefFoundError:
org/springframework/beans/factory/xml/DefaultXmlBeanDefinitionParser
	at
org.apache.xbean.spring.context.ResourceXmlApplicationContext.loadBeanDefinitions(ResourceXmlApplicationContext.java:87)
	at
org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:89)
	at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:283)
	at
org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:64)
	at
org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:52)

Now, since I can't directly bind the "peer://" protocol on a BrokerService,
and the BrokerFactoryBean only takes a config location to find the Xbean XML
configuration, I'm stuck I guess... Probably have to build my own
FactoryBean or something, which means more delays getting set up...
-- 
View this message in context: http://www.nabble.com/ActiveMQ-with-Spring-2.0--tf2011356.html#a5527075
Sent from the ActiveMQ - User forum at Nabble.com.


Re: ActiveMQ with Spring 2.0?

Posted by jcarreira <jc...@gmail.com>.
Arghh... I hate using snapshots but...

Oh, well.. I've downloaded the latest snapshot. Is there anywhere to get the
source? It doesn't seem to be in the snapshot zip file (and don't tell me to
pull it from SVN, I want the source as of that build). 
-- 
View this message in context: http://www.nabble.com/ActiveMQ-with-Spring-2.0--tf2011356.html#a5544636
Sent from the ActiveMQ - User forum at Nabble.com.


Re: ActiveMQ with Spring 2.0?

Posted by James Strachan <ja...@gmail.com>.
We've fixed 4.1-SNAPSHOT to use the latest xbean-spring (2.5) and it
works fine with spring 2.0-rc2 but 4.0.1 is dependent on an older
xbean and spring 1.x only I'm afraid.

Though you could just configure the broker in Java code or using the
traditional Spring XML if you prefer - e.g. mimicking the Java code
shown on this page...

http://incubator.apache.org/activemq/how-do-i-embed-a-broker-inside-a-connection.html

On 7/27/06, jcarreira <jc...@gmail.com> wrote:
>
> Anyone using ActiveMQ 4.0.1 with Spring 2.0 ?
>
> I've found that the XBean configuration isn't usable, since it apparently
> depends on an old version of Spring. Here's the error:
>
> org.springframework.beans.factory.BeanCreationException: Error creating bean
> with name 'broker' defined in class path resource [jmsContext.xml]:
> Invocation of init method failed; nested exception is
> java.lang.NoClassDefFoundError:
> org/springframework/beans/factory/xml/DefaultXmlBeanDefinitionParser
> Caused by:
> java.lang.NoClassDefFoundError:
> org/springframework/beans/factory/xml/DefaultXmlBeanDefinitionParser
>         at
> org.apache.xbean.spring.context.ResourceXmlApplicationContext.loadBeanDefinitions(ResourceXmlApplicationContext.java:87)
>         at
> org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:89)
>         at
> org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:283)
>         at
> org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:64)
>         at
> org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:52)
>
> Now, since I can't directly bind the "peer://" protocol on a BrokerService,
> and the BrokerFactoryBean only takes a config location to find the Xbean XML
> configuration, I'm stuck I guess... Probably have to build my own
> FactoryBean or something, which means more delays getting set up...
> --
> View this message in context: http://www.nabble.com/ActiveMQ-with-Spring-2.0--tf2011356.html#a5527075
> Sent from the ActiveMQ - User forum at Nabble.com.
>
>


-- 

James
-------
http://radio.weblogs.com/0112098/

Re: ActiveMQ with Spring 2.0?

Posted by jcarreira <jc...@gmail.com>.
Want to share? ;-)


Sanjiv Jivan wrote:
> 
> I'm using Active MQ 4.0.1 with Spring 2.0 but have my own java bean
> wrapper
> for ActiveMQ configuration instead of XBean configuration.
> 
> 
> 
> On 7/27/06, jcarreira <jc...@gmail.com> wrote:
>>
>>
>> Anyone using ActiveMQ 4.0.1 with Spring 2.0 ?
>>
>> I've found that the XBean configuration isn't usable, since it apparently
>> depends on an old version of Spring. Here's the error:
>>
>> org.springframework.beans.factory.BeanCreationException: Error creating
>> bean
>> with name 'broker' defined in class path resource [jmsContext.xml]:
>> Invocation of init method failed; nested exception is
>> java.lang.NoClassDefFoundError:
>> org/springframework/beans/factory/xml/DefaultXmlBeanDefinitionParser
>> Caused by:
>> java.lang.NoClassDefFoundError:
>> org/springframework/beans/factory/xml/DefaultXmlBeanDefinitionParser
>>        at
>>
>> org.apache.xbean.spring.context.ResourceXmlApplicationContext.loadBeanDefinitions
>> (ResourceXmlApplicationContext.java:87)
>>        at
>>
>> org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory
>> (AbstractRefreshableApplicationContext.java:89)
>>        at
>> org.springframework.context.support.AbstractApplicationContext.refresh(
>> AbstractApplicationContext.java:283)
>>        at
>> org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(
>> ResourceXmlApplicationContext.java:64)
>>        at
>> org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(
>> ResourceXmlApplicationContext.java:52)
>>
>> Now, since I can't directly bind the "peer://" protocol on a
>> BrokerService,
>> and the BrokerFactoryBean only takes a config location to find the Xbean
>> XML
>> configuration, I'm stuck I guess... Probably have to build my own
>> FactoryBean or something, which means more delays getting set up...
>> --
>> View this message in context:
>> http://www.nabble.com/ActiveMQ-with-Spring-2.0--tf2011356.html#a5527075
>> Sent from the ActiveMQ - User forum at Nabble.com.
>>
>>
> 
> 
-- 
View this message in context: http://www.nabble.com/ActiveMQ-with-Spring-2.0--tf2011356.html#a5533222
Sent from the ActiveMQ - User forum at Nabble.com.


Re: ActiveMQ with Spring 2.0?

Posted by Sanjiv Jivan <sa...@gmail.com>.
I'm using Active MQ 4.0.1 with Spring 2.0 but have my own java bean wrapper
for ActiveMQ configuration instead of XBean configuration.



On 7/27/06, jcarreira <jc...@gmail.com> wrote:
>
>
> Anyone using ActiveMQ 4.0.1 with Spring 2.0 ?
>
> I've found that the XBean configuration isn't usable, since it apparently
> depends on an old version of Spring. Here's the error:
>
> org.springframework.beans.factory.BeanCreationException: Error creating
> bean
> with name 'broker' defined in class path resource [jmsContext.xml]:
> Invocation of init method failed; nested exception is
> java.lang.NoClassDefFoundError:
> org/springframework/beans/factory/xml/DefaultXmlBeanDefinitionParser
> Caused by:
> java.lang.NoClassDefFoundError:
> org/springframework/beans/factory/xml/DefaultXmlBeanDefinitionParser
>        at
>
> org.apache.xbean.spring.context.ResourceXmlApplicationContext.loadBeanDefinitions
> (ResourceXmlApplicationContext.java:87)
>        at
>
> org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory
> (AbstractRefreshableApplicationContext.java:89)
>        at
> org.springframework.context.support.AbstractApplicationContext.refresh(
> AbstractApplicationContext.java:283)
>        at
> org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(
> ResourceXmlApplicationContext.java:64)
>        at
> org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(
> ResourceXmlApplicationContext.java:52)
>
> Now, since I can't directly bind the "peer://" protocol on a
> BrokerService,
> and the BrokerFactoryBean only takes a config location to find the Xbean
> XML
> configuration, I'm stuck I guess... Probably have to build my own
> FactoryBean or something, which means more delays getting set up...
> --
> View this message in context:
> http://www.nabble.com/ActiveMQ-with-Spring-2.0--tf2011356.html#a5527075
> Sent from the ActiveMQ - User forum at Nabble.com.
>
>