activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ikbenben <ben.roo...@desato.com>
Subject Re: jdbcPersistence behaviour
Date Wed, 12 Dec 2007 16:11:59 GMT

bump :)


ikbenben wrote:
> 
> Hey James,
> 
> thanks for the feedback.  i had read the docs.  
> 
> just to be sure i am understanding correctly, suppose we have 2 jboss
> nodes in a cluster, both with activemq-ra.rar and jbossweb-tomcat55.sar
> deployed.  then, when the 1st node is started, both the activemq and
> tomcat modules will complete their startup correctly and be available. 
> however, when the 2nd node is started, it will hang indefinitely while it
> tries to get a db lock for active mq and the tomcat module will never be
> available.  this applies to any other services that have been deployed in
> the cluster (ie jndi, webservices, scheduling, etc...)
> 
> if this is true, then it seems like there is not any reason or advantage
> to embed activemq in a jboss cluster.
> 
> i would have thought it would behave similar to how ha-jms works in jboss. 
> all servers in the cluster complete their startup sequence completely but
> only a first node to be started in the cluster has the active jms
> provider.  the other nodes in the cluster have a proxy to that first node
> so any requests to the local jms gets redirected to the first node's jms
> provider.  in the end all the other deployed services on every jboss node
> are available.
> 
> am i understanding things correct?  what is the typical architecture then
> if i have a web application deployed in a jboss cluster that needs to use
> jms and i want that jms provider to be active mq?  
> 
> btw, the whole reason for this is that jbossMQ has issues and most people
> have migrated to activeMQ instead.
> 
> cheers
> ben
> 
> 
> James.Strachan wrote:
>> 
>> On 11/11/2007, ikbenben <ben.rooney@desato.com> wrote:
>>>
>>> hey all,
>>>
>>> i've got a question regarding the behaviour of using the
>>> jdbcPersistenceAdaptor.  i have deployed ActiveMQ into a clustered JBoss
>>> 4.0.5 environment.  I basically have 2 JBoss servers, each of which has
>>> the
>>> ActiveMQ RAR deployed.  I've attached the broker xml file for reference:
>>> http://www.nabble.com/file/p13696937/broker.xml broker.xml
>>>
>>> When i start up the JBoss servers, the first server comes up correctly
>>> but
>>> the second jboss instance hangs during start up while it is trying to
>>> get a
>>> lock on the database (activemq).  when i shut down server one, the
>>> second
>>> instance continues and finishes the start up.  is this how it should
>>> behave?
>> 
>> Yes - the first broker to start is the master, it locks the database -
>> the others are slaves.
>> 
>> http://activemq.apache.org/jdbc-master-slave.html
>> 
>> If you don't want the brokers to be a master/slave cluster, then just
>> use a different database for each broker; though then you probably
>> will want to network your brokers together to make a store and forward
>> network.
>> 
>> 
>>> the reason i'm asking was i intended to deploy a EAR file in the jboss
>>> instance on each server which would use activemq tp send messages to
>>> other
>>> applications.  however, if the second instance doesn't come up ever then
>>> this won't work as i need to ensure i have clustering working on the EAR
>>> level.
>> 
>> So either run your master/slave brokers separately to your jboss
>> servers (e.g. running the bin/activemq command) or try figure out how
>> to do an async start in jboss, or run the brokers in separate jboss
>> servers? Note that the RAR can connect to a remote broker - it doesn't
>> need to boot up an ActiveMQ broker
>> 
>> -- 
>> James
>> -------
>> http://macstrac.blogspot.com/
>> 
>> Open Source SOA
>> http://open.iona.com
>> 
>> 
> 
> 

-- 
View this message in context: http://www.nabble.com/jdbcPersistence-behaviour-tp13696937s2354p14298283.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.


Mime
View raw message