On Mon, Mar 1, 2010 at 2:54 PM, <antel...@apache.org> wrote: > Author: antelder > Date: Mon Mar 1 22:54:24 2010 > New Revision: 917777 > > URL: http://svn.apache.org/viewvc?rev=917777&view=rev > Log: > Fix to ensure pass-by-value is used if only one end is using > allowsPassByReference > > Modified: > > tuscany/sca-java-2.x/trunk/modules/binding-sca-runtime/src/main/java/org/apache/tuscany/sca/binding/sca/provider/RuntimeSCAReferenceBindingProvider.java > > Modified: > tuscany/sca-java-2.x/trunk/modules/binding-sca-runtime/src/main/java/org/apache/tuscany/sca/binding/sca/provider/RuntimeSCAReferenceBindingProvider.java > URL: > http://svn.apache.org/viewvc/tuscany/sca-java-2.x/trunk/modules/binding-sca-runtime/src/main/java/org/apache/tuscany/sca/binding/sca/provider/RuntimeSCAReferenceBindingProvider.java?rev=917777&r1=917776&r2=917777&view=diff > ============================================================================== > --- > tuscany/sca-java-2.x/trunk/modules/binding-sca-runtime/src/main/java/org/apache/tuscany/sca/binding/sca/provider/RuntimeSCAReferenceBindingProvider.java > (original) > +++ > tuscany/sca-java-2.x/trunk/modules/binding-sca-runtime/src/main/java/org/apache/tuscany/sca/binding/sca/provider/RuntimeSCAReferenceBindingProvider.java > Mon Mar 1 22:54:24 2010 > @@ -208,7 +208,8 @@ > passByValue = false; > } > } else { > - boolean allowsPBR = chain.allowsPassByReference(); > +// boolean allowsPBR = chain.allowsPassByReference(); > TODO: TUSCANY-3479 this breaks the conformance tests as it needs to consider > _both_ ends > + boolean allowsPBR = false; > if (allowsPBR && > interfaceContractMapper.isCompatibleByReference(operation, targetOp, > Compatibility.SUBSET)) { > passByValue = false; > } else if > (interfaceContractMapper.isCompatibleByValue(operation, targetOp, > Compatibility.SUBSET)) { > > >
This always assume PBV, which will cause extra and unnecessary transformation and degrade performance. Instead of hacking the core runtime, we should really look into the root cause of the issue and fix it. I'd rather really disable the conformance test. -- Luciano Resende http://people.apache.org/~lresende http://twitter.com/lresende1975 http://lresende.blogspot.com/