On Tue, Oct 20, 2009 at 7:03 AM, Douglas Leite <[email protected]> wrote: > Ok, > > But let's suppose that I want to invoke, inside an invoker, a different > operation from a component. > > For this invocation chain: > > 1) add -> Interceptor for the add -> Interceptor for the addMethod -> > addMethod > > Suppose that I want to invoke the addMethod2 instead of addMetdhod, and both > operation belong to the same component. In this way, I cannot use the > getNext().invoke(msg); > > I am trying to create a different invoker: > > RuntimeComponent component = msg.getTo().getComponent(); > ImplementationProvider implProvider = > component.getImplementationProvider(); > implProvider.createInvoker(RuntimeComponentService arg1, Operation arg2); > > However, I am having some problems to create a RuntimeComponentService and a > Operation for the addMethod2. Is it possible? Am I doing the right thing, or > there is another way to do it? > > Thanks >
What I'm trying to say is, if you specify what is the reason or the problem you are trying to solve, we could probably give you a better solution or indeed ratify you are on the right path. BTW, Look at operation selector in 1.x or I think JMS Binding in 2.x, this goes around selecting the the operation to be invoked, and this seems more like what you are trying to do... (e.g instead of you calling the operation, you just select a different one) -- Luciano Resende http://people.apache.org/~lresende http://lresende.blogspot.com/
