Description of problem: Version-Release number of selected component (if applicable): How reproducible: Steps to Reproduce: 1. 2. 3. Actual results: Expected results: Additional info:
Description of problem: during application server startup there is race condition between internal connector services which can end in NullPointerException: 15:19:59,963 ERROR [org.jboss.msc.service.fail] (ResourceAdapterDeploymentService Thread Pool -- 1) MSC000001: Failed to start service jboss.ra.deployment."X.rar:main_X-ra": org.jboss.msc.service.StartException in service jboss.ra.deployment."X.rar:main_X": JBAS010446: Failed to start RA deployment [X] at org.jboss.as.connector.services.resourceadapters.deployment.AbstractResourceAdapterDeploymentService$1.run(AbstractResourceAdapterDeploymentService.java:279) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) at org.jboss.threads.JBossThread.run(JBossThread.java:122) Caused by: org.jboss.jca.deployers.common.DeployException: IJ020051: Unable to start org.jboss.resource.adapter.jms.JmsResourceAdapter at org.jboss.jca.deployers.common.AbstractResourceAdapterDeployer.startContext(AbstractResourceAdapterDeployer.java:360) at org.jboss.jca.deployers.common.AbstractResourceAdapterDeployer.createObjectsAndInjectValue(AbstractResourceAdapterDeployer.java:2470) at org.jboss.as.connector.services.resourceadapters.deployment.ResourceAdapterXmlDeploymentService$AS7RaXmlDeployer.doDeploy(ResourceAdapterXmlDeploymentService.java:185) at org.jboss.as.connector.services.resourceadapters.deployment.ResourceAdapterXmlDeploymentService.start(ResourceAdapterXmlDeploymentService.java:106) at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1980) at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1913) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) Caused by: java.lang.NullPointerException at org.jboss.jca.deployers.common.AbstractResourceAdapterDeployer.startContext(AbstractResourceAdapterDeployer.java:347) ... 8 more Version-Release number of selected component (if applicable): 6.4.4 How reproducible: hard to reproduce since most of the times services start in correct order Steps to Reproduce: 1. configure any RA 2. start application server Actual results: sometimes NPE occurs. Expected results: no NPE, as starts without ERRORs. Additional info: proposed solution attached as diff. It fixes this bug occurance but I'm not sure it covers all cases.
Created attachment 1096104 [details] proposed fix
Comment on attachment 1096104 [details] proposed fix Let me clarify. The patch fixes only requests for default context. I haven't investigated the case when raxml or iron jacamar descriptor requests non default context. In such a case possibly new dependency is needed - a dynamically created one.
Hi Michal, Thanks for the patch. I'm looking at WildFly and seeing a construct which should allow for differently named default contexts. https://github.com/wildfly/wildfly/commit/5b1a2c51961dbf723a82dbb27a1cbbd68e756992#diff-f6120489a40c27419b57a24fa0994c8a Be advised that we normally do not process Bugzilla's filed directly, without having an associated filing at the Customer Portal. [1] I'll pass this BZ on to support and see how they wish to proceed. [1] https://access.redhat.com/products/red-hat-jboss-enterprise-application-platform/support-information
Verified with EAP 6.4.17.CP.CR4
Released on 2017-09-05 as part of the EAP 6.4.17 release.