User development,

A new message was posted in the thread "Lookup up a POJO service without 
injecting it inside -beans.xml?":

http://community.jboss.org/message/522543#522543

Author  : Ales Justin
Profile : http://community.jboss.org/people/alesj

Message:
--------------------------------------------------------------
Zdravo :-)
 
> The "getInstalledContext("SvcB")" from ServiceA.java fails. It suggest some 
> sort of scoping is at play because if I look up SvcA from ServiceA, it works 
> just fine.  I want to be able to look up a service just the same as if it is 
> injected to me via "<inject bean=" from any service. Is this possible? Thanks!
 
No scoping. ;-)
I think I know what the problem is.
 
You're doing the lookup to soon.
At the moment you try to find *installed* SvcB, that one is *not* installed yet.
 
You can either
* try to do lookup via getContext("SvcB", null)
* make sure when SvcA invoked init, SvcB is already *fully* installed; SvcA 
depends on SvcB at Installed state
 
If this is not it, post the stack trace you're catching in init.

--------------------------------------------------------------

To reply to this message visit the message page: 
http://community.jboss.org/message/522543#522543


_______________________________________________
jboss-user mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to