You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by "Scott Kurz (JIRA)" <de...@tuscany.apache.org> on 2009/04/14 15:51:15 UTC

[jira] Created: (TUSCANY-2962) Throw an exception if multiple same-name operations are detected by WSDL intf introspector

Throw an exception if multiple same-name operations are detected by WSDL intf introspector
------------------------------------------------------------------------------------------

                 Key: TUSCANY-2962
                 URL: https://issues.apache.org/jira/browse/TUSCANY-2962
             Project: Tuscany
          Issue Type: Improvement
          Components: Java SCA Core Runtime
            Reporter: Scott Kurz
            Priority: Minor


I noticed that a particular user error involving a badly-formed WSDL can be hard to debug.   

In my case (will attach example)  I have the binding input/output @name not matching the portType input/output @name.   Though wsimport has no problem generating Java compatible with my WSDL, the WSDL4J library processes my WSDL as having two distinct Operation(s) for my portType (will attach a sample program to show what I mean).

Given the time it took me to realize what was going on later (I'll spare you the details), it seems a useful thing to do would have been for the WSDL introspector to flag this as an error instead of letting me go any further.  

Any issues with adding this type of validation?

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


[jira] Updated: (TUSCANY-2962) Throw an exception if multiple same-name operations are detected by WSDL intf introspector

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

Scott Kurz updated TUSCANY-2962:
--------------------------------

    Attachment: MyMain.java
                test.wsdl

> Throw an exception if multiple same-name operations are detected by WSDL intf introspector
> ------------------------------------------------------------------------------------------
>
>                 Key: TUSCANY-2962
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2962
>             Project: Tuscany
>          Issue Type: Improvement
>          Components: Java SCA Core Runtime
>            Reporter: Scott Kurz
>            Priority: Minor
>         Attachments: MyMain.java, test.wsdl
>
>
> I noticed that a particular user error involving a badly-formed WSDL can be hard to debug.   
> In my case (will attach example)  I have the binding input/output @name not matching the portType input/output @name.   Though wsimport has no problem generating Java compatible with my WSDL, the WSDL4J library processes my WSDL as having two distinct Operation(s) for my portType (will attach a sample program to show what I mean).
> Given the time it took me to realize what was going on later (I'll spare you the details), it seems a useful thing to do would have been for the WSDL introspector to flag this as an error instead of letting me go any further.  
> Any issues with adding this type of validation?

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


[jira] Resolved: (TUSCANY-2962) Throw an exception if multiple same-name operations are detected by WSDL intf introspector

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

Ramkumar Ramalingam resolved TUSCANY-2962.
------------------------------------------

    Resolution: Fixed

Committed at revision 773823 in 1.x.

> Throw an exception if multiple same-name operations are detected by WSDL intf introspector
> ------------------------------------------------------------------------------------------
>
>                 Key: TUSCANY-2962
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2962
>             Project: Tuscany
>          Issue Type: Improvement
>          Components: Java SCA Core Runtime
>            Reporter: Scott Kurz
>            Assignee: Ramkumar Ramalingam
>            Priority: Minor
>         Attachments: MyMain.java, test.wsdl
>
>
> I noticed that a particular user error involving a badly-formed WSDL can be hard to debug.   
> In my case (will attach example)  I have the binding input/output @name not matching the portType input/output @name.   Though wsimport has no problem generating Java compatible with my WSDL, the WSDL4J library processes my WSDL as having two distinct Operation(s) for my portType (will attach a sample program to show what I mean).
> Given the time it took me to realize what was going on later (I'll spare you the details), it seems a useful thing to do would have been for the WSDL introspector to flag this as an error instead of letting me go any further.  
> Any issues with adding this type of validation?

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


[jira] Assigned: (TUSCANY-2962) Throw an exception if multiple same-name operations are detected by WSDL intf introspector

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

Ramkumar Ramalingam reassigned TUSCANY-2962:
--------------------------------------------

    Assignee: Ramkumar Ramalingam

> Throw an exception if multiple same-name operations are detected by WSDL intf introspector
> ------------------------------------------------------------------------------------------
>
>                 Key: TUSCANY-2962
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2962
>             Project: Tuscany
>          Issue Type: Improvement
>          Components: Java SCA Core Runtime
>            Reporter: Scott Kurz
>            Assignee: Ramkumar Ramalingam
>            Priority: Minor
>         Attachments: MyMain.java, test.wsdl
>
>
> I noticed that a particular user error involving a badly-formed WSDL can be hard to debug.   
> In my case (will attach example)  I have the binding input/output @name not matching the portType input/output @name.   Though wsimport has no problem generating Java compatible with my WSDL, the WSDL4J library processes my WSDL as having two distinct Operation(s) for my portType (will attach a sample program to show what I mean).
> Given the time it took me to realize what was going on later (I'll spare you the details), it seems a useful thing to do would have been for the WSDL introspector to flag this as an error instead of letting me go any further.  
> Any issues with adding this type of validation?

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


[jira] Commented: (TUSCANY-2962) Throw an exception if multiple same-name operations are detected by WSDL intf introspector

Posted by "Scott Kurz (JIRA)" <de...@tuscany.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-2962?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12698777#action_12698777 ] 

Scott Kurz commented on TUSCANY-2962:
-------------------------------------

If you run MyMain against the (bad) test.wsdl, you'll see the multiple WSDL4J Operations.

> Throw an exception if multiple same-name operations are detected by WSDL intf introspector
> ------------------------------------------------------------------------------------------
>
>                 Key: TUSCANY-2962
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2962
>             Project: Tuscany
>          Issue Type: Improvement
>          Components: Java SCA Core Runtime
>            Reporter: Scott Kurz
>            Priority: Minor
>         Attachments: MyMain.java, test.wsdl
>
>
> I noticed that a particular user error involving a badly-formed WSDL can be hard to debug.   
> In my case (will attach example)  I have the binding input/output @name not matching the portType input/output @name.   Though wsimport has no problem generating Java compatible with my WSDL, the WSDL4J library processes my WSDL as having two distinct Operation(s) for my portType (will attach a sample program to show what I mean).
> Given the time it took me to realize what was going on later (I'll spare you the details), it seems a useful thing to do would have been for the WSDL introspector to flag this as an error instead of letting me go any further.  
> Any issues with adding this type of validation?

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


[jira] Commented: (TUSCANY-2962) Throw an exception if multiple same-name operations are detected by WSDL intf introspector

Posted by "Scott Kurz (JIRA)" <de...@tuscany.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-2962?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12708974#action_12708974 ] 

Scott Kurz commented on TUSCANY-2962:
-------------------------------------

Thanks Ram,

That seems like a definite improvement.   Interesting that you decided not to detect the error based on finding two similarly-named operations.    I wonder if there are any advantages to your way of doing it over mine, but I think yours will definitely work to detect the error cases I had in mine.



> Throw an exception if multiple same-name operations are detected by WSDL intf introspector
> ------------------------------------------------------------------------------------------
>
>                 Key: TUSCANY-2962
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2962
>             Project: Tuscany
>          Issue Type: Improvement
>          Components: Java SCA Core Runtime
>            Reporter: Scott Kurz
>            Assignee: Ramkumar Ramalingam
>            Priority: Minor
>         Attachments: MyMain.java, test.wsdl
>
>
> I noticed that a particular user error involving a badly-formed WSDL can be hard to debug.   
> In my case (will attach example)  I have the binding input/output @name not matching the portType input/output @name.   Though wsimport has no problem generating Java compatible with my WSDL, the WSDL4J library processes my WSDL as having two distinct Operation(s) for my portType (will attach a sample program to show what I mean).
> Given the time it took me to realize what was going on later (I'll spare you the details), it seems a useful thing to do would have been for the WSDL introspector to flag this as an error instead of letting me go any further.  
> Any issues with adding this type of validation?

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


[jira] Commented: (TUSCANY-2962) Throw an exception if multiple same-name operations are detected by WSDL intf introspector

Posted by "Ramkumar Ramalingam (JIRA)" <de...@tuscany.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-2962?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12707968#action_12707968 ] 

Ramkumar Ramalingam commented on TUSCANY-2962:
----------------------------------------------

Hi Scott,

As you have mentioned, the WSDL4J tries to process the WSDL as if its having two distinct Operations.

In this case, we should be able to throw an exception by checking getMessage() of the operation's input and output....

if (operation.getInput().getMessage() == null) {
        throw error;
}
if (operation.getOutput().getMessage() == null) {
        throw error;
}

I hope this will generate the required error message.

> Throw an exception if multiple same-name operations are detected by WSDL intf introspector
> ------------------------------------------------------------------------------------------
>
>                 Key: TUSCANY-2962
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2962
>             Project: Tuscany
>          Issue Type: Improvement
>          Components: Java SCA Core Runtime
>            Reporter: Scott Kurz
>            Assignee: Ramkumar Ramalingam
>            Priority: Minor
>         Attachments: MyMain.java, test.wsdl
>
>
> I noticed that a particular user error involving a badly-formed WSDL can be hard to debug.   
> In my case (will attach example)  I have the binding input/output @name not matching the portType input/output @name.   Though wsimport has no problem generating Java compatible with my WSDL, the WSDL4J library processes my WSDL as having two distinct Operation(s) for my portType (will attach a sample program to show what I mean).
> Given the time it took me to realize what was going on later (I'll spare you the details), it seems a useful thing to do would have been for the WSDL introspector to flag this as an error instead of letting me go any further.  
> Any issues with adding this type of validation?

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


[jira] Commented: (TUSCANY-2962) Throw an exception if multiple same-name operations are detected by WSDL intf introspector

Posted by "Scott Kurz (JIRA)" <de...@tuscany.apache.org>.
    [ https://issues.apache.org/jira/browse/TUSCANY-2962?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12709621#action_12709621 ] 

Scott Kurz commented on TUSCANY-2962:
-------------------------------------

Since an operation could have null Input or Output, added a fix to guard against NPE in 774957 in 1.x

> Throw an exception if multiple same-name operations are detected by WSDL intf introspector
> ------------------------------------------------------------------------------------------
>
>                 Key: TUSCANY-2962
>                 URL: https://issues.apache.org/jira/browse/TUSCANY-2962
>             Project: Tuscany
>          Issue Type: Improvement
>          Components: Java SCA Core Runtime
>            Reporter: Scott Kurz
>            Assignee: Ramkumar Ramalingam
>            Priority: Minor
>         Attachments: MyMain.java, test.wsdl
>
>
> I noticed that a particular user error involving a badly-formed WSDL can be hard to debug.   
> In my case (will attach example)  I have the binding input/output @name not matching the portType input/output @name.   Though wsimport has no problem generating Java compatible with my WSDL, the WSDL4J library processes my WSDL as having two distinct Operation(s) for my portType (will attach a sample program to show what I mean).
> Given the time it took me to realize what was going on later (I'll spare you the details), it seems a useful thing to do would have been for the WSDL introspector to flag this as an error instead of letting me go any further.  
> Any issues with adding this type of validation?

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