geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeremy Boynes <>
Subject Resource ref as dependency; WAS: Multiple Inheritance
Date Sun, 03 Oct 2004 19:26:41 GMT
toby cabot wrote:
> On a (hopefully) related topic, what's the mechanism to declare the
> dependencies within an ear?  I ask because I've got a webapp that uses
> a connector and despite a <resource-ref> in web.xml and a
> <resource-ref> in geronimo-jetty.xml I get 
> javax.naming.NamingException: could not look up : env/ra/CF [Root exception is java.lang.IllegalStateException:
Proxy not returned. Target geronimo.server:J2EEServer=geronimo,j2eeType=JCAManagedConnectionFactory,name=testCF
not started] 
> when I start the server.  I assumed that the <resource-ref> provided
> the dependency data to the server, but if there's some other technique
> I need to use I'll try that.

I think this is a reasonable assumption - it certainly makes sense from 
the application's viewpoint.

I should not be that hard to do - after all at deployment time we know 
all the references a component is making and what they will ultimately 
resolve to. Seeing as any attempt to use the resource will fail, then we 
might as well not start the component.

The big downside I see is that it means a component won't start unless 
all its local references can be resolved. This could be an issue if 
there is logic in the code that chooses between references based on 
application-level criteria. Perhaps we should add a flag to the 
resource-ref that tags it as mandatory (we create a dependency) or 
optional (we don't).


View raw message