I agree that PBV should be the responsibility of binding/implementation providers. IMO, binding.sca should not be handled specically. binding.sca should be the one that sets up the PBV interceptor if necessary.
Thanks, Raymond From: Simon Laws Sent: Friday, February 13, 2009 4:35 AM To: [email protected] Subject: Re: [1.x][2.x] Over zealous PBV handler insertion On Fri, Feb 13, 2009 at 12:19 PM, Simon Nash <[email protected]> wrote: Simon Laws wrote: Around line 155 of DataBindingRuntimeWireProcessor there is the code // assume pass-by-values copies are required if interfaces are remotable and there is no data binding // transformation, i.e. a transformation will result in a copy so another pass-by-value copy is unnecessary if (!isOnMessage(targetOperation) && isRemotable(chain, sourceOperation, targetOperation)) { interceptor = new PassByValueInterceptor(dataBindings, faultExceptionMapper, chain, targetOperation); } We should only be doing this if binding.sca is being used. TUSCANY-2586 records this problem but there seems to be some question as to the solution. Why can't we check here what type of binding is being used? Iassuming that that approach was discounted. Simon > It isn't safe to assume that all bindings other than binding.sca force copies to be made. A user could write binding.foo that works similarly to binding.sca in that it doesn't do copies on local invocations. The solution proposed in the discussion of TUSCANY-2586 solves this problem by making every binding responsible for deciding whether the copying needs to be done. Simon Ok, good point. My thought was also rubbish as binding.sca doesn't always need the PBV interceptor:-( So we need a new binding operation to ask the question whether a copy is required. In the binding.sca case it needs to take account of whether it's operating in local or remote mode. Simon
