You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by "Shu Chao Wan (JIRA)" <de...@tuscany.apache.org> on 2009/01/15 15:34:59 UTC

[jira] Created: (TUSCANY-2770) Missing warning message when verifying connformance item 50011

Missing warning message when verifying connformance item 50011
--------------------------------------------------------------

                 Key: TUSCANY-2770
                 URL: https://issues.apache.org/jira/browse/TUSCANY-2770
             Project: Tuscany
          Issue Type: Bug
          Components: Java SCA Assembly Model
    Affects Versions: Java-SCA-1.3
            Reporter: Shu Chao Wan
            Priority: Minor


I have a question about conformance item 50011 and hope some one could help me.
 
Conformance item 50011 tells something about some constraints about interface of <component>'s <reference>.  And here is the detailed description:
 "A reference has zero or one interface, which describes the operations required by the reference. The interface is described by an interface element which is a child element of the reference element. If no interface is specified, then the interface specified for the reference in the componentType of the implementation is in effect. If an interface is declared for a component reference it MUST provide a compatible superset of the interface declared for the equivalent reference in the componentType of the implementation, i.e. provide the same operations or a superset of the operations defined by the implementation for the reference. "
In my opinion, I think it is to say that interface declared for a component reference must have equal or more operations than its implementation acturally need. So I write a composite file wire.composite and testcase to verify it.
 
-----------------------------
wire.composite
-----------------------------
<composite>...
   <component name="FComponent">
     <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.FServiceImpl"/>
     <reference name="d">
        <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.DSubService" />
     </reference>
     <reference name="c">
         <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.CSubService" />
     </reference>
  </component>
   <component name="CComponent">
        <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.CServiceImpl"/>
        <service name="CService"> 
            <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.CService"/>
        </service>     
    </component>
    <component name="DComponent">
        <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.DServiceImpl"/>
        <service name="DService"> 
            <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.DService" />
        </service>        
    </component>    
    <wire source="FComponent/d" target="DComponent" />
    <wire source="FComponent/c" target="CComponent" />
</composite>
 
---------------------------
FServiceImpl.java
---------------------------
@Service(FService.class)
public class FServiceImpl implements FService {
    @Reference
    protected CService c;
    
    @Reference
    protected DService d;
}
 
Here, CSubService and DSubService are sub sets of CService and DService respectively.
 
When loading this composite file, I haven't got any error message or even warning message, which supposed to appear. 
And when I switch the CSubService to  CSuperService and DSubService to DSuperService (CSuperService and DSuperService are super sets of CService and DService respectively), I got warning message this time.
WARNING: Component reference interface incompatible with reference interface: Component = FComponent Reference = d
WARNING: Component reference interface incompatible with reference interface: Component = FComponent Reference = c
 
It seems that it works just on the opposite to the specification. Is there anything wrong with it? 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (TUSCANY-2770) Missing warning message when verifying connformance item 50011

Posted by "Shu Chao Wan (JIRA)" <de...@tuscany.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-2770?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12681268#action_12681268 ] 

Shu Chao Wan commented on TUSCANY-2770:
---------------------------------------

This defect is about conformance item 50011 and is NOT contained by patch for TUSCANY-2884.  So please apply the above patch ASM50011.patch if you want to look into this problem.

> Missing warning message when verifying connformance item 50011
> --------------------------------------------------------------
>
>                 Key: TUSCANY-2770
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2770
>             Project: Tuscany
>          Issue Type: Bug
>          Components: Java SCA Assembly Model
>    Affects Versions: Java-SCA-1.3
>            Reporter: Shu Chao Wan
>            Priority: Minor
>         Attachments: ASM50011.patch
>
>
> I have a question about conformance item 50011 and hope some one could help me.
>  
> Conformance item 50011 tells something about some constraints about interface of <component>'s <reference>.  And here is the detailed description:
>  "A reference has zero or one interface, which describes the operations required by the reference. The interface is described by an interface element which is a child element of the reference element. If no interface is specified, then the interface specified for the reference in the componentType of the implementation is in effect. If an interface is declared for a component reference it MUST provide a compatible superset of the interface declared for the equivalent reference in the componentType of the implementation, i.e. provide the same operations or a superset of the operations defined by the implementation for the reference. "
> In my opinion, I think it is to say that interface declared for a component reference must have equal or more operations than its implementation acturally need. So I write a composite file wire.composite and testcase to verify it.
>  
> -----------------------------
> wire.composite
> -----------------------------
> <composite>...
>    <component name="FComponent">
>      <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.FServiceImpl"/>
>      <reference name="d">
>         <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.DSubService" />
>      </reference>
>      <reference name="c">
>          <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.CSubService" />
>      </reference>
>   </component>
>    <component name="CComponent">
>         <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.CServiceImpl"/>
>         <service name="CService"> 
>             <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.CService"/>
>         </service>     
>     </component>
>     <component name="DComponent">
>         <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.DServiceImpl"/>
>         <service name="DService"> 
>             <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.DService" />
>         </service>        
>     </component>    
>     <wire source="FComponent/d" target="DComponent" />
>     <wire source="FComponent/c" target="CComponent" />
> </composite>
>  
> ---------------------------
> FServiceImpl.java
> ---------------------------
> @Service(FService.class)
> public class FServiceImpl implements FService {
>     @Reference
>     protected CService c;
>     
>     @Reference
>     protected DService d;
> }
>  
> Here, CSubService and DSubService are sub sets of CService and DService respectively.
>  
> When loading this composite file, I haven't got any error message or even warning message, which supposed to appear. 
> And when I switch the CSubService to  CSuperService and DSubService to DSuperService (CSuperService and DSuperService are super sets of CService and DService respectively), I got warning message this time.
> WARNING: Component reference interface incompatible with reference interface: Component = FComponent Reference = d
> WARNING: Component reference interface incompatible with reference interface: Component = FComponent Reference = c
>  
> It seems that it works just on the opposite to the specification. Is there anything wrong with it? 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (TUSCANY-2770) Missing warning message when verifying connformance item 50011

Posted by "Shu Chao Wan (JIRA)" <de...@tuscany.apache.org>.
     [ https://issues.apache.org/jira/browse/TUSCANY-2770?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shu Chao Wan updated TUSCANY-2770:
----------------------------------

    Attachment: ASM50011.patch

> Missing warning message when verifying connformance item 50011
> --------------------------------------------------------------
>
>                 Key: TUSCANY-2770
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2770
>             Project: Tuscany
>          Issue Type: Bug
>          Components: Java SCA Assembly Model
>    Affects Versions: Java-SCA-1.3
>            Reporter: Shu Chao Wan
>            Priority: Minor
>         Attachments: ASM50011.patch
>
>
> I have a question about conformance item 50011 and hope some one could help me.
>  
> Conformance item 50011 tells something about some constraints about interface of <component>'s <reference>.  And here is the detailed description:
>  "A reference has zero or one interface, which describes the operations required by the reference. The interface is described by an interface element which is a child element of the reference element. If no interface is specified, then the interface specified for the reference in the componentType of the implementation is in effect. If an interface is declared for a component reference it MUST provide a compatible superset of the interface declared for the equivalent reference in the componentType of the implementation, i.e. provide the same operations or a superset of the operations defined by the implementation for the reference. "
> In my opinion, I think it is to say that interface declared for a component reference must have equal or more operations than its implementation acturally need. So I write a composite file wire.composite and testcase to verify it.
>  
> -----------------------------
> wire.composite
> -----------------------------
> <composite>...
>    <component name="FComponent">
>      <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.FServiceImpl"/>
>      <reference name="d">
>         <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.DSubService" />
>      </reference>
>      <reference name="c">
>          <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.CSubService" />
>      </reference>
>   </component>
>    <component name="CComponent">
>         <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.CServiceImpl"/>
>         <service name="CService"> 
>             <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.CService"/>
>         </service>     
>     </component>
>     <component name="DComponent">
>         <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.DServiceImpl"/>
>         <service name="DService"> 
>             <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.DService" />
>         </service>        
>     </component>    
>     <wire source="FComponent/d" target="DComponent" />
>     <wire source="FComponent/c" target="CComponent" />
> </composite>
>  
> ---------------------------
> FServiceImpl.java
> ---------------------------
> @Service(FService.class)
> public class FServiceImpl implements FService {
>     @Reference
>     protected CService c;
>     
>     @Reference
>     protected DService d;
> }
>  
> Here, CSubService and DSubService are sub sets of CService and DService respectively.
>  
> When loading this composite file, I haven't got any error message or even warning message, which supposed to appear. 
> And when I switch the CSubService to  CSuperService and DSubService to DSuperService (CSuperService and DSuperService are super sets of CService and DService respectively), I got warning message this time.
> WARNING: Component reference interface incompatible with reference interface: Component = FComponent Reference = d
> WARNING: Component reference interface incompatible with reference interface: Component = FComponent Reference = c
>  
> It seems that it works just on the opposite to the specification. Is there anything wrong with it? 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (TUSCANY-2770) Missing warning message when verifying connformance item 50011

Posted by "Simon Laws (JIRA)" <de...@tuscany.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-2770?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12681239#action_12681239 ] 

Simon Laws commented on TUSCANY-2770:
-------------------------------------

The reported error is still valid but the patch here can be ignored as the patch for TUSCANY-2884 committed all the test cases together at  revision: 752817  

> Missing warning message when verifying connformance item 50011
> --------------------------------------------------------------
>
>                 Key: TUSCANY-2770
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2770
>             Project: Tuscany
>          Issue Type: Bug
>          Components: Java SCA Assembly Model
>    Affects Versions: Java-SCA-1.3
>            Reporter: Shu Chao Wan
>            Priority: Minor
>         Attachments: ASM50011.patch
>
>
> I have a question about conformance item 50011 and hope some one could help me.
>  
> Conformance item 50011 tells something about some constraints about interface of <component>'s <reference>.  And here is the detailed description:
>  "A reference has zero or one interface, which describes the operations required by the reference. The interface is described by an interface element which is a child element of the reference element. If no interface is specified, then the interface specified for the reference in the componentType of the implementation is in effect. If an interface is declared for a component reference it MUST provide a compatible superset of the interface declared for the equivalent reference in the componentType of the implementation, i.e. provide the same operations or a superset of the operations defined by the implementation for the reference. "
> In my opinion, I think it is to say that interface declared for a component reference must have equal or more operations than its implementation acturally need. So I write a composite file wire.composite and testcase to verify it.
>  
> -----------------------------
> wire.composite
> -----------------------------
> <composite>...
>    <component name="FComponent">
>      <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.FServiceImpl"/>
>      <reference name="d">
>         <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.DSubService" />
>      </reference>
>      <reference name="c">
>          <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.CSubService" />
>      </reference>
>   </component>
>    <component name="CComponent">
>         <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.CServiceImpl"/>
>         <service name="CService"> 
>             <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.CService"/>
>         </service>     
>     </component>
>     <component name="DComponent">
>         <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.DServiceImpl"/>
>         <service name="DService"> 
>             <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.DService" />
>         </service>        
>     </component>    
>     <wire source="FComponent/d" target="DComponent" />
>     <wire source="FComponent/c" target="CComponent" />
> </composite>
>  
> ---------------------------
> FServiceImpl.java
> ---------------------------
> @Service(FService.class)
> public class FServiceImpl implements FService {
>     @Reference
>     protected CService c;
>     
>     @Reference
>     protected DService d;
> }
>  
> Here, CSubService and DSubService are sub sets of CService and DService respectively.
>  
> When loading this composite file, I haven't got any error message or even warning message, which supposed to appear. 
> And when I switch the CSubService to  CSuperService and DSubService to DSuperService (CSuperService and DSuperService are super sets of CService and DService respectively), I got warning message this time.
> WARNING: Component reference interface incompatible with reference interface: Component = FComponent Reference = d
> WARNING: Component reference interface incompatible with reference interface: Component = FComponent Reference = c
>  
> It seems that it works just on the opposite to the specification. Is there anything wrong with it? 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (TUSCANY-2770) Missing warning message when verifying connformance item 50011

Posted by "Simon Laws (JIRA)" <de...@tuscany.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-2770?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12681275#action_12681275 ] 

Simon Laws commented on TUSCANY-2770:
-------------------------------------

Oops sorry Susan, I changed one too many.


> Missing warning message when verifying connformance item 50011
> --------------------------------------------------------------
>
>                 Key: TUSCANY-2770
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2770
>             Project: Tuscany
>          Issue Type: Bug
>          Components: Java SCA Assembly Model
>    Affects Versions: Java-SCA-1.3
>            Reporter: Shu Chao Wan
>            Priority: Minor
>         Attachments: ASM50011.patch
>
>
> I have a question about conformance item 50011 and hope some one could help me.
>  
> Conformance item 50011 tells something about some constraints about interface of <component>'s <reference>.  And here is the detailed description:
>  "A reference has zero or one interface, which describes the operations required by the reference. The interface is described by an interface element which is a child element of the reference element. If no interface is specified, then the interface specified for the reference in the componentType of the implementation is in effect. If an interface is declared for a component reference it MUST provide a compatible superset of the interface declared for the equivalent reference in the componentType of the implementation, i.e. provide the same operations or a superset of the operations defined by the implementation for the reference. "
> In my opinion, I think it is to say that interface declared for a component reference must have equal or more operations than its implementation acturally need. So I write a composite file wire.composite and testcase to verify it.
>  
> -----------------------------
> wire.composite
> -----------------------------
> <composite>...
>    <component name="FComponent">
>      <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.FServiceImpl"/>
>      <reference name="d">
>         <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.DSubService" />
>      </reference>
>      <reference name="c">
>          <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.CSubService" />
>      </reference>
>   </component>
>    <component name="CComponent">
>         <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.CServiceImpl"/>
>         <service name="CService"> 
>             <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.CService"/>
>         </service>     
>     </component>
>     <component name="DComponent">
>         <implementation.java class="org.apache.tuscany.sca.vtest.assembly.composite.impl.DServiceImpl"/>
>         <service name="DService"> 
>             <interface.java interface="org.apache.tuscany.sca.vtest.assembly.composite.DService" />
>         </service>        
>     </component>    
>     <wire source="FComponent/d" target="DComponent" />
>     <wire source="FComponent/c" target="CComponent" />
> </composite>
>  
> ---------------------------
> FServiceImpl.java
> ---------------------------
> @Service(FService.class)
> public class FServiceImpl implements FService {
>     @Reference
>     protected CService c;
>     
>     @Reference
>     protected DService d;
> }
>  
> Here, CSubService and DSubService are sub sets of CService and DService respectively.
>  
> When loading this composite file, I haven't got any error message or even warning message, which supposed to appear. 
> And when I switch the CSubService to  CSuperService and DSubService to DSuperService (CSuperService and DSuperService are super sets of CService and DService respectively), I got warning message this time.
> WARNING: Component reference interface incompatible with reference interface: Component = FComponent Reference = d
> WARNING: Component reference interface incompatible with reference interface: Component = FComponent Reference = c
>  
> It seems that it works just on the opposite to the specification. Is there anything wrong with it? 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.