On Thu, Mar 3, 2011 at 3:57 PM, Richard Yao <[email protected]> wrote: > Hi, > > The question I am going to ask is a generic SCA question, I already posted it > in Fabric3 forum. I would like to ask help here as well. > > --------------------------------------------------------------- > > Let's say I have a test case is A calls B and B calls C. > > A is SCA component, A has a Spring POJO reference to B. > B is POJO, B needs to call SCA component C. > C is SCA component. > > My question is how B can "lookup" a SCA component C? My understanding is B is > POJO - not defined in composite file - I can not use SCA to inject a > reference of C into B. > > Thanks, > Richard
Hi Richard The OASIS version of SCA (what Tuscany 2.x code is based on) defines a Java client that hides the look up for you. Talking generically you can read about it in Section 5 of the Java Common Annotations and SPIs specification [1]. >From your scenario though what context is B running in? As A has a Spring POJO reference to B does this mean B is a Java object in the Spring environment? [1] http://docs.oasis-open.org/opencsa/sca-j/sca-javacaa-1.1-spec.pdf Regards Simon -- Apache Tuscany committer: tuscany.apache.org Co-author of a book about Tuscany and SCA: tuscanyinaction.com
