Raymond,

Raymond Feng wrote:
Hi,

We use either JDK or CGLib proxies in reference injections for java components. It is a bit heavy and unnecessary for some cases. I now add a simple optimization to inject the implementation instance directly if the following criteria are met:

1) Both the source and target are java components
2) The binding is local SCA binding
3) The target implementation class implements/extends the source interface/class
4) The target component scope is either STATELESS or COMPOSITE
5) There is only one invoker (JavaImplementationInvoker) in each invocation chain for all the operations

What do you think?

Thanks,
Raymond


This kind of optimisation has always been part of the idea behind SCA, so in general, I think this is fine.

There are probably a lot of wrinkles (Simon's note mentions some) and I suggest that this should be prototyped and checked out before going into the mainline code.

Yours,  Mike.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to