Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 165921 - WS-I Attachments Profile 1.0 compliant WSDL fails validation in WSDL editor
Summary: WS-I Attachments Profile 1.0 compliant WSDL fails validation in WSDL editor
Status: CLOSED DUPLICATE of bug 161410
Alias: None
Product: WTP Webservices
Classification: WebTools
Component: wst.wsdl (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 critical (vote)
Target Milestone: ---   Edit
Assignee: wst.wsdl CLA
QA Contact: Craig Salter CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-11-27 10:10 EST by John O'Shea CLA
Modified: 2006-11-28 15:52 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description John O'Shea CLA 2006-11-27 10:10:55 EST
There is a problem with the WSDL validator that causes it to report errors on WS-I Attachments Profile 1.0 (1) compliant WSDL files.

The source of the problem is the org.wsdl4j\xsd\wsdl-mime.xsd file.  There are a couple of issues (originally documented by a colleague at (2))

1) This schema specifies that the name attribute on mime:part elements is required.  However, the WS-I AP spec clearly shows several WSDL documents containing mime:part elements that have no name attribute:

2) This schema specifies that mime:part elements can only contain elements from the mime namespace.  However, again, the WS-I specification clearly shows several WSDL documents that have mime:part elements containing soap:body elements (as is the common usage for the soap-with-attachment-message-body use case)

3) The 'official' mime:xsd schema ("http://schemas.xmlsoap.org/wsdl/mime/") does not correctly require the mime:part elements be qualified.  In fact, I see that you have already modified your org.wsdl4j/xsd/wsdl-mime.xsd to fix this (defining  mime:multipartRelated as containing a "<element ref="mime:part"..." rather than the official "<element name="part" type="mime:tPart"...".  So this one is ok.

Would it be possible to implement fixes for 1) & 2) by changing the definition of mime:part to something like

<complexType name="tPart">
  <sequence>
    <any minOccurs="0" maxOccurs="unbounded"/>
  </sequence>
  <attribute name="name" type="NMTOKEN" use="optional"/>
</complexType>

This will *relax* the editor validation slightly so that it allows WS-I AP compliant documents to be validated successfully.   At the moment, compliant documents are causing invalid validation error markers to appear in the Problems view in the workbench, misleading users into thinking that their WSDL files are not compliant.

(Note: this bug report is slightly related to https://bugs.eclipse.org/bugs/show_bug.cgi?id=145583)

(1)http://www.ws-i.org/Profiles/AttachmentsProfile-1.0.html
(2)http://tech.groups.yahoo.com/group/soapbuilders/message/10724
Comment 1 Valentin Baciu CLA 2006-11-27 10:50:13 EST
I believe this problem is already tracked as https://bugs.eclipse.org/bugs/show_bug.cgi?id=161410.  In there you will also find a workaround you can use until the correct MIME schema is incorporated in the WSDL4J plug-in.
Comment 2 John O'Shea CLA 2006-11-27 10:59:09 EST
Valentin,
  Unfortunately our users would not typically be well qualified to perform the steps listed in 161410 every time they create a workspace - even if we could force them to do so!  

  I am curious now though. Would defining a "org.eclipse.wst.xml.core.catalogContributions" extension that contributes to a non-default catalog override the use of the org.wsdl4j schema by the WSDL validator at runtime?  
The doc on the catalogContribtions extension point are a little unclear on the interpretation of the id attribute on the catalogContribution element.

(In reply to comment #1)
> I believe this problem is already tracked as
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=161410.  In there you will also
> find a workaround you can use until the correct MIME schema is incorporated in
> the WSDL4J plug-in.
> 

Comment 3 Craig Salter CLA 2006-11-28 13:57:46 EST

*** This bug has been marked as a duplicate of bug 161410 ***
Comment 4 John Lanuti CLA 2006-11-28 15:52:01 EST
This is part of a mass update to close out all stale WTP bugs which are in the resolved state without an appropriate targeted version.  If you feel this bug was closed inappropriately, please reopen.