You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by miniman <be...@db.com> on 2007/01/22 15:40:34 UTC

BUG in JBOSS ActiveMQ Bridge

All i found an issue with the VM option and JBOSS integreation.

When you enable the vm option in the ra.xml file in your jboss installation
to say 

	   
<!--<config-property-value>tcp://localhost:61616</config-property-value>-->
	    <config-property-value>vm://localhost</config-property-value>

And then startup your activemq within jboss. When using a simple MDB to
listen to a queue or topic 
you are not able to see messages, but if you use an external consumer you
can. If you leave activemq inside jboss
and then change the option above to

	    <config-property-value>tcp://localhost:61616</config-property-value>
	   <!-- <config-property-value>vm://localhost</config-property-value>-->

It all works fine.  

Bug maybe ?




-- 
View this message in context: http://www.nabble.com/BUG-in-JBOSS-ActiveMQ-Bridge-tf3058045.html#a8502469
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Re: BUG in JBOSS ActiveMQ Bridge

Posted by James Strachan <ja...@gmail.com>.
On 1/23/07, miniman <be...@db.com> wrote:
>
> I setup the activemq to use the VM option, so that my MDB that was deployed
> in jboss could listen to the activemq channels. When i configure my MDB to
> listen to the channels as per the websites instructions, messages are being
> sent into the channel but the MDB is not seeing them. When you change the
> ra.xml option from vm to tcp you see the messages.

Is Jboss the only JVM? Or are you running a separate broker? Note that
vm:// cannot communicate to another broker - just to the same JVM.
Also note that vm:// can only communicate with the broker in the same
*ClassLoader* - so in a J2EE app server it could just be that the
class loader your code is in cannot see the broker that other code can
see (so you in effect have 2 brokers).

If you are using different class loaders, I'd stick to tcp

-- 

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

Re: BUG in JBOSS ActiveMQ Bridge

Posted by miniman <be...@db.com>.
I setup the activemq to use the VM option, so that my MDB that was deployed
in jboss could listen to the activemq channels. When i configure my MDB to
listen to the channels as per the websites instructions, messages are being
sent into the channel but the MDB is not seeing them. When you change the
ra.xml option from vm to tcp you see the messages.



James.Strachan wrote:
> 
> On 1/22/07, miniman <be...@db.com> wrote:
>>
>> All i found an issue with the VM option and JBOSS integreation.
>>
>> When you enable the vm option in the ra.xml file in your jboss
>> installation
>> to say
>>
>>
>> <!--<config-property-value>tcp://localhost:61616</config-property-value>-->
>>             <config-property-value>vm://localhost</config-property-value>
>>
>> And then startup your activemq within jboss. When using a simple MDB to
>> listen to a queue or topic
>> you are not able to see messages, but if you use an external consumer you
>> can.
> 
> Using vm://localhost will connect to the broker inside the same JVM
> (thats visible in the same class loader) whereas tcp:// will connect
> over TCP to a remote JVM.
> 
> So when you say you can't see a queue/topic or can with an external
> consumer - are you referring to a separate broker running?  Providing
> its the same broker you're talking about - vm or tcp will work the
> same.
> 
> -- 
> 
> James
> -------
> http://radio.weblogs.com/0112098/
> 
> 

-- 
View this message in context: http://www.nabble.com/BUG-in-JBOSS-ActiveMQ-Bridge-tf3058045.html#a8516803
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Re: BUG in JBOSS ActiveMQ Bridge

Posted by James Strachan <ja...@gmail.com>.
On 1/22/07, miniman <be...@db.com> wrote:
>
> All i found an issue with the VM option and JBOSS integreation.
>
> When you enable the vm option in the ra.xml file in your jboss installation
> to say
>
>
> <!--<config-property-value>tcp://localhost:61616</config-property-value>-->
>             <config-property-value>vm://localhost</config-property-value>
>
> And then startup your activemq within jboss. When using a simple MDB to
> listen to a queue or topic
> you are not able to see messages, but if you use an external consumer you
> can.

Using vm://localhost will connect to the broker inside the same JVM
(thats visible in the same class loader) whereas tcp:// will connect
over TCP to a remote JVM.

So when you say you can't see a queue/topic or can with an external
consumer - are you referring to a separate broker running?  Providing
its the same broker you're talking about - vm or tcp will work the
same.

-- 

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

Re: BUG in JBOSS ActiveMQ Bridge

Posted by James Strachan <ja...@gmail.com>.
On 1/23/07, miniman <be...@db.com> wrote:
>
> How do i tell if my producer is sending to the other broker and not the
> embedded one, when i start my producer it is just publishing messages to
> localhost 61616

If you are not explicitly starting another broker - you just have
JBoss running with an embedded broker - then I suspect its a
classloader issue, the consumer seeing a different broker maybe?

-- 

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

Re: BUG in JBOSS ActiveMQ Bridge

Posted by miniman <be...@db.com>.
How do i tell if my producer is sending to the other broker and not the
embedded one, when i start my producer it is just publishing messages to
localhost 61616



Adrian Co wrote:
> 
> VM option starts an embedded broker. Most probably your consumer is 
> consuming from the embedded broker and your producer is publishing to 
> another broker. That's why you are not seeing the messages.
> 
> miniman wrote:
>> All i found an issue with the VM option and JBOSS integreation.
>>
>> When you enable the vm option in the ra.xml file in your jboss
>> installation
>> to say 
>>
>> 	   
>> <!--<config-property-value>tcp://localhost:61616</config-property-value>-->
>> 	    <config-property-value>vm://localhost</config-property-value>
>>
>> And then startup your activemq within jboss. When using a simple MDB to
>> listen to a queue or topic 
>> you are not able to see messages, but if you use an external consumer you
>> can. If you leave activemq inside jboss
>> and then change the option above to
>>
>> 	    <config-property-value>tcp://localhost:61616</config-property-value>
>> 	   <!-- <config-property-value>vm://localhost</config-property-value>-->
>>
>> It all works fine.  
>>
>> Bug maybe ?
>>
>>
>>
>>
>>   
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/BUG-in-JBOSS-ActiveMQ-Bridge-tf3058045.html#a8517039
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Re: BUG in JBOSS ActiveMQ Bridge

Posted by Adrian Co <ac...@exist.com>.
VM option starts an embedded broker. Most probably your consumer is 
consuming from the embedded broker and your producer is publishing to 
another broker. That's why you are not seeing the messages.

miniman wrote:
> All i found an issue with the VM option and JBOSS integreation.
>
> When you enable the vm option in the ra.xml file in your jboss installation
> to say 
>
> 	   
> <!--<config-property-value>tcp://localhost:61616</config-property-value>-->
> 	    <config-property-value>vm://localhost</config-property-value>
>
> And then startup your activemq within jboss. When using a simple MDB to
> listen to a queue or topic 
> you are not able to see messages, but if you use an external consumer you
> can. If you leave activemq inside jboss
> and then change the option above to
>
> 	    <config-property-value>tcp://localhost:61616</config-property-value>
> 	   <!-- <config-property-value>vm://localhost</config-property-value>-->
>
> It all works fine.  
>
> Bug maybe ?
>
>
>
>
>