Hi,

 

I'm trying to find a way to implement following need with Felix and
iPojo.

 

Imagine you have an iPojo instance of Bundle A calling an OSGi Service
provided by an iPojo instance of Bundle B.

Imagine this Bundle B iPojo instance is calling an OSGi Service provided
by an iPojo instance of Bundle C.

 

class A {

@Requires

B b;

 

public doSomething() {

                                ...

                                b.doSomethingInB();

}

}

 

class B {

@Requires

C c;

 

public doSomethingInB() {

                                ...

                                c.doSomethingInC();

}

}

 

class C {

public doSomethingInC() {

                                ...

}

}

 

What I want is to be able to send some "contextual" information from
method "doSomething()" in class A to method "doSomethingInC()" in class
C without being intrusive in the method signature.

For example, this contextual information could be created by class A
with the username.

This context could be enriched by class B by adding the user email for
example.

And finally the class C could get the username and user email from the
contextual information without adding this data as parameter of its
method.

 

Do you have an idea how I can do that with iPojo?

 

Thanks

Olivier

Reply via email to