[jboss-as7-dev] Error reporting and deployment failure for services with unresolved dependencies

Jaikiran Pai jpai at redhat.com
Mon Feb 7 08:13:31 EST 2011


While integrating EJB3 service into current AS trunk, I noticed that if 
a Component's service (or any service in general) has unresolved 
dependencies, although the service stays in DOWN state (as expected), no 
error is reported and the deployment does *not* fail. As a side effect 
of this, a runtime invocation on the service (a InitialContext.lookup() 
leading to the ServiceReferenceObjectFactory.getObjectInstance() in this 
case) ended up hanging indefinitely http://pastebin.com/jK0i1aCi

To debug this, I had to use jconsole and then get a list of all the 
services, their dependencies and the state and then figure out what's 
missing:

Service 
"jboss.deployment.unit.ejb3-example.jar.component.SimpleStatelessSessionBean" 
(class org.jboss.as.ee.component.service.ComponentService) mode ACTIVE 
state DOWN (dependencies: 
jboss.naming.context.java.module.ejb3-example.jar, 
jboss.naming.context.java.app.ejb3-example.jar, 
jboss.naming.context.java.comp.ejb3-example.jar.SimpleStatelessSessionBean, 
jboss.naming.context.java.global."ejb3-example/SimpleStatelessSessionBean!org.jboss.as.demos.ejb3.archive.SimpleStatelessSessionLocal") 
(has missing dependency)

Shouldn't a unresolved dependency on a service result in deployment failure?

-Jaikiran


-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-as7-dev/attachments/20110207/13ceef0e/attachment.html 


More information about the jboss-as7-dev mailing list