On Sat, Jul 17, 2010 at 12:25 AM,  <[email protected]> wrote:
> Author: rfeng
> Date: Fri Jul 16 23:25:36 2010
> New Revision: 964980
>
> URL: http://svn.apache.org/viewvc?rev=964980&view=rev
> Log:
> Fix the regression caused by r963624 for overloaded local methods
>
> Modified:
>    
> tuscany/sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/assembly/impl/RuntimeEndpointImpl.java
>
> Modified: 
> tuscany/sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/assembly/impl/RuntimeEndpointImpl.java
> URL: 
> http://svn.apache.org/viewvc/tuscany/sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/assembly/impl/RuntimeEndpointImpl.java?rev=964980&r1=964979&r2=964980&view=diff
> ==============================================================================
> --- 
> tuscany/sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/assembly/impl/RuntimeEndpointImpl.java
>  (original)
> +++ 
> tuscany/sca-java-2.x/trunk/modules/core/src/main/java/org/apache/tuscany/sca/core/assembly/impl/RuntimeEndpointImpl.java
>  Fri Jul 16 23:25:36 2010
> @@ -230,9 +230,18 @@ public class RuntimeEndpointImpl extends
>                 // chain is created. As the chain operations are the real 
> interface types
>                 // they may be incompatible just because they are described 
> in different
>                 // IDLs
> -                if (operation.getName().equals(op.getName())) {
> -                    invocationChainMap.put(operation, chain);
> -                    return chain;
> +                if (operation.getInterface().isRemotable()) {
> +                    if (operation.getName().equals(op.getName())) {
> +                        invocationChainMap.put(operation, chain);
> +                        return chain;
> +                    }
> +                } else {
> +                    // [rfeng] We need to run the compatibility check for 
> local operations as they
> +                    // can be overloaded
> +                    if (interfaceContractMapper.isCompatible(operation, op, 
> Compatibility.SUBSET)) {
> +                        invocationChainMap.put(operation, chain);
> +                        return chain;
> +                    }
>                 }
>             }
>             // Cache it with the NULL_CHAIN to avoid NPE
>
>
>

Hi Raymond

Which test was it that alerted you to the regression? I didn't spot
the problem when I made the original change which worries me a bit.

Simon

-- 
Apache Tuscany committer: tuscany.apache.org
Co-author of a book about Tuscany and SCA: tuscanyinaction.com

Reply via email to