-
1. Re: Clustered Singleton Service and MDBs
adrian.brock Feb 25, 2005 5:43 PM (in response to inders1)4) Put your mdb in deploy-hasingleton
5) Create your own deploy-hasingleton-service.xml and use the mdb's url
Number (3) is quite a good idea, but difficult to implement with the current
HA Singleton, since you cannot do the following in java:SingletonJMSContainerInvoker extends JMSContainerInvoker, HASingletonSupport
which is why "singleton" will be implemented as a microcontainer aspect in JBoss5 -
2. Re: Clustered Singleton Service and MDBs
inders1 Feb 25, 2005 7:35 PM (in response to inders1)Thanks Adrian.
I will look into (4) and (5) to see if that helps me.
Else, I believe I will have to find my way around to implement (3), by using an HASingletonSupport implementation that is a controller for SingletonJMSContainerInvoker.
Will keep posted on which route I finally take.
-Inder. -
3. Re: Clustered Singleton Service and MDBs
inders1 Mar 3, 2005 6:22 PM (in response to inders1)I am trying to go with approach (4) - put my MDB in deploy-hasingleton, but it doesnot seem to work. (Note- when I put my MDBs in deploy or farm folder, it works just fine).
Here is the exception I get on startup:
15:13:46,546 WARN [EjbModule] Could not load the org.jboss.resource.connectionm
anager.CachedConnectionInterceptor interceptor for this container
javax.management.InstanceNotFoundException: jboss.jca:service=CachedConnectionManager is not registered....
...
MBeans waiting for other MBeans:
ObjectName: jboss.j2ee:binding=message-driven-bean,jndiName=local/DefaultProvide
rMDB,plugin=invoker,service=EJB
state: FAILED
I Depend On:
Depends On Me: javax.naming.NameNotFoundException: DefaultJMSProvider not bound
MBEANS THAT ARE THE ROOT CAUSE OF THE PROBLEM:
ObjectName: jboss.j2ee:binding=message-driven-bean,jndiName=local/DefaultProvide
rMDB,plugin=invoker,service=EJB
state: FAILED
I Depend On:
Depends On Me: javax.naming.NameNotFoundException: DefaultJMSProvider not bound
I am running in 'all' mode and have ensured that jmsjca-service.xml is in the deploy folder. Also, since I am using SonicMQ, and not JBossMQ, I have removed JBossMQ related configurations.
My sonic-service.xml looks something like this:<?xml version="1.0" encoding="UTF-8"?> <server> <mbean code="com.integral.jmsx.jndi.jboss.JBossLoader" name="sonic.mq:service=JNDILoader"> <attribute name="JNDIInitClassName">com.integral.jmsx.jndi.JmsJndiInit</attribute> <depends>jboss:service=Naming</depends> </mbean> <!-- The JMS provider loader --> <mbean code="org.jboss.jms.jndi.JMSProviderLoader" name="jboss.mq:service=JMSProviderLoader,name=JBossMQProvider"> <attribute name="ProviderName">DefaultJMSProvider</attribute> <attribute name="ProviderAdapterClass"> org.jboss.jms.jndi.JNDIProviderAdapter </attribute> <attribute name="QueueFactoryRef">java:/QueueConnectionFactory</attribute> <attribute name="TopicFactoryRef">java:/TopicConnectionFactory</attribute> </mbean> <!-- org.jboss.jms.jndi.JNDIProviderAdapter --> <!-- The server session pool for Message Driven Beans --> <mbean code="org.jboss.jms.asf.ServerSessionPoolLoader" name="jboss.mq:service=ServerSessionPoolMBean,name=StdJMSPool"> <depends optional-attribute-name="XidFactory">jboss:service=XidFactory</depends> <attribute name="PoolName">StdJMSPool</attribute> <attribute name="PoolFactoryClass"> org.jboss.jms.asf.StdServerSessionPoolFactory </attribute> </mbean> <!-- JMS XA Resource adapter, use this to get transacted JMS in beans --> <tx-connection-factory> <jndi-name>JmsXA</jndi-name> <xa-transaction/> <rar-name>jms-ra.rar</rar-name> <connection-definition>org.jboss.resource.adapter.jms.JmsConnectionFactory</connection-definition> <config-property name="SessionDefaultType" type="java.lang.String">javax.jms.Topic</config-property> <config-property name="JmsProviderAdapterJNDI" type="java.lang.String">java:/DefaultJMSProvider</config-property> <max-pool-size>20</max-pool-size> <security-domain-and-application>JmsXARealm</security-domain-and-application> </tx-connection-factory> </server>
-Thanks.
-Inder.