Deployed RA startup sequence

171 views
Skip to first unread message

Samhain

unread,
May 22, 2014, 7:48:40 AM5/22/14
to jboss-gene...@googlegroups.com

I have deployed and configured the Generic JMS resource adapter in my EAP 6.1 server under the standalone-full.xml resource-adapters subsystem.

 

<subsystem xmlns="urn:jboss:domain:resource-adapters:1.1">

            <resource-adapters>

                <resource-adapter id="generic-jms-ra.rar">

                    <archive>

                        generic-jms-ra.rar

                    </archive>

                    <transaction-support>NoTransaction</transaction-support>

                    <connection-definitions>

                        <connection-definition class-name="org.jboss.resource.adapter.jms.JmsManagedConnectionFactory" jndi-name="java:/GenericJmsXA" enabled="true" use-java-context="true" pool-name="GenericJmsXA" use-ccm="true">

                            <config-property name="JndiParameters">

                                java.naming.factory.initial=com.tibco.tibjms.naming.TibjmsInitialContextFactory;java.naming.provider.url=tcp://X.X.X.X:7222,tcp://X.X.X.X:7222

                            </config-property>

                            <config-property name="ConnectionFactory">

                                QueueConnectionFactory

                            </config-property>

                            <pool>

                                <min-pool-size>0</min-pool-size>

                                <max-pool-size>50</max-pool-size>

                                <prefill>false</prefill>

                                <use-strict-min>false</use-strict-min>

                                <flush-strategy>FailingConnectionOnly</flush-strategy>

                            </pool>

                            <security>

                                <application/>

                            </security>

                        </connection-definition>

                    </connection-definitions>

                </resource-adapter>

     </resource-adapters>

</subsystem>

 

I'm able to leverage this connection factory without issue in a WAR by using resource injection like:

 

@Resource(mappedName="java:/GenericJmsXA", type=JmsConnectionFactory.class)

JmsConnectionFactory connectionFactory2;


 

I'm also able to bind it for inbound in an MDB without issue as well.


Sometimes, when I start up EAP 6.1 however, I get the following error:

 

10:42:00,525 INFO  [org.jboss.as.controller] (Controller Boot Thread) JBAS014774: Service status report

JBAS014775:    New missing/unsatisfied dependencies:

      service jboss.naming.context.java.GenericJmsXA (missing) dependents: [service jboss.naming.context.java.module.JBossSecure.JBossSecure.env."com.mak.testing.SecureService".connectionFactory2, service jboss.naming.context.java.module.JBossSecure.JBossSecure.env.GenericJmsXA]

 

This is completely random, so it has to be some sort of dependancy/startup order issue where the resource adapter hasn't been fully started prior to the WAR or MDB starting.  Sometimes only a single WAR doesn't bind, sometimes the MDB, sometimes both.  If, when the server starts up in this state, I undeploy the WAR or the MDB, I get the following message:

 

10:58:48,236 INFO  [org.jboss.as.controller] (DeploymentScanner-threads - 2) JBAS014774: Service status report

JBAS014776:    Newly corrected services:

      service jboss.naming.context.java.GenericJmsXA (no longer required)

 

How do you "remind" JBoss of this dependancy?  Or is there a way to install the RAR so that it doesn't get redeployed every time the server starts up?

 

Things I've tried:

1)   Added " Dependencies: deployment.generic-jms-ra.rar" to my WAR's MANIFEST.MF

2)   Added <module name="deployment.generic-jms.ra.rar"/> to my WAR's jboss-deployment-structure.xml

3)   Added <resource-ref> elements to my WAR's web.xml

Samhain

unread,
May 22, 2014, 7:55:37 AM5/22/14
to jboss-gene...@googlegroups.com
This sounds very familiar to this open bug, although I don't think its opened on the correct project:  https://issues.jboss.org/browse/WFLY-1968

Either way, the same issue is present: If this appears in the logs, everything works

13:14:59,080 INFO  [org.jboss.as.connector.deployment] (MSC service thread 1-1) JBAS010401: Bound JCA ConnectionFactory [java:/GenericJmsXA]

Its almost like when JBoss is processing the resource adapters, if it doesn't think anyone requires it, it doesn't bind the deployed connection-definitions.

Samhain

unread,
May 22, 2014, 9:41:54 AM5/22/14
to jboss-gene...@googlegroups.com
I have now also tried turning off the deployments subsystem.

I can successfully deploy all of the pieces( RAR, WAR, MDB ) via the CLI only.

Still seeing the same issue on restarts where the "Bound JCA ConnectionFactory [java:/GenericJmsXA]" message is missing, which causes the WAR/MDB to not function.

Additionally, I also randomly see this message as well: "09:37:05,875 INFO  [org.apache.cxf.common.injection.ResourceInjector] (MSC service thread 1-6) failed to resolve resource com.mak.testing.SecureService/connectionFactory2", even when the JCA ConnectionFactory is bound correctly.  Interestingly, though, the connectionFactory2 resource is injected correctly even though this message makes it seem as though it wasn't.

Justin Bertram

unread,
May 22, 2014, 10:43:35 AM5/22/14
to jboss-gene...@googlegroups.com
All your issues here are with JBoss EAP, and not with the JCA RA itself.  This group is specifically for issues with the JCA RA.

I recommend the following:
  • If you don't have a Red Hat support subscription then post to the appropriate community forum.
  • If you do have a Red Hat support subscription then open a ticket.
  • Move to WildFly as it appears the issue has been resolved there according to this comment.

Samhain

unread,
May 22, 2014, 10:48:56 AM5/22/14
to jboss-gene...@googlegroups.com
Alrighty then.  Wasn't sure if I just "installed" the RA incorrectly.  Thanks
Reply all
Reply to author
Forward
0 new messages