Bug 965515 - SY quickstart validate-xml JBDS errors/warnings
SY quickstart validate-xml JBDS errors/warnings
Status: MODIFIED
Product: JBoss Fuse Service Works 6
Classification: JBoss
Component: Examples, SwitchYard (Show other bugs)
6.0.0
Unspecified Unspecified
unspecified Severity unspecified
: DR4
: ---
Assigned To: Douglas Palmer
ppecka
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-05-21 06:22 EDT by ppecka
Modified: 2014-11-19 01:46 EST (History)
7 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
You will see warning messages in JBoss Developer Studio's "Problems" view after you import a validate-xml quick start as a Maven project.
Story Points: ---
Clone Of:
Environment:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
JBoss Issue Tracker SWITCHYARD-1652 Major Reopened SY quickstart validate-xml JBDS errors/warnings 2015-07-28 08:36:44 EDT
JBoss Issue Tracker SWITCHYARD-1654 Major Closed SY Editor validator erroneously reports errors for missing transformers 2015-07-28 08:36:43 EDT
JBoss Issue Tracker SWITCHYARD-2385 Major Resolved Cleanup problems/warnings when importing quick starts into JBDS 2015-07-28 08:36:43 EDT

  None (edit)
Description ppecka 2013-05-21 06:22:00 EDT
Description of problem:
Warnings/Errors found in JBDS "Problems" View, right after quickstart is imported as maven project.

steps to reproduce:
1. Start JBDS
2. import existing maven project
3. Window / Show View / Problems
4. check for errors

Actual results:

Required transformation missing: from="java:java.lang.String" to="{urn:switchyard-quickstart:validate-xml:0.1.0}orderAck".  switchyard.xml  /switchyard-quickstart-validate-xml/src/main/resources/META-INF Unknown SwitchYard

Required transformation missing: from="{urn:switchyard-quickstart:validate-xml:0.1.0}order" to="java:java.lang.String". switchyard.xml  /switchyard-quickstart-validate-xml/src/main/resources/META-INF Unknown SwitchYard

schema_reference.4: Failed to read schema document 'orders.base', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.   orders.xsd  /switchyard-quickstart-validate-xml/src/main/resources/xsd  line 6  XML Schema Problem

src-resolve: Cannot resolve the name 'base:order.base' to a(n) 'element declaration' component. orders.xsd  /switchyard-quickstart-validate-xml/src/main/resources/xsd  line 8  XML Schema Problem

Unused Capability: The "Camel Route" capability is configured on the project, but is not required by any SwitchYard binding or implementation types used in the project.    switchyard.xml  /switchyard-quickstart-validate-xml/src/main/resources/META-INF Unknown SwitchYard


Expected results:
No warnings/errors in JBDS

Additional info:
Comment 1 JBoss JIRA Server 2013-08-16 14:28:47 EDT
Brian Fitzpatrick <bfitzpat@redhat.com> made a comment on jira SWITCHYARD-1652

Patch fixes the unnecessary component reference in the pom
Comment 2 JBoss JIRA Server 2013-08-19 12:05:31 EDT
Brian Fitzpatrick <bfitzpat@redhat.com> made a comment on jira SWITCHYARD-1652

PR removes unneeded camel component from pom, which eliminates the warning seen when importing the project in the tooling. The transformation errors will be resolved by the PR for SWITCHYARD-1654.
Comment 3 JBoss JIRA Server 2013-08-23 14:30:12 EDT
Rob Cernich <rcernich@redhat.com> made a comment on jira SWITCHYARD-1654

pushed
Comment 4 JBoss JIRA Server 2013-08-27 10:02:04 EDT
Keith Babo <kbabo@redhat.com> made a comment on jira SWITCHYARD-1652

pushed
Comment 8 Andrej Podhradsky 2013-11-18 07:09:57 EST
After importing the quickstart 'validate-xml' there are the following error:

src-resolve: Cannot resolve the name 'base:order.base' to a(n) 'element declaration' component.

in /switchyard-quickstart-validate-xml/src/main/resources/xsd/orders.xsd
Comment 9 Rob Cernich 2013-11-18 10:50:11 EST
It appears the schemaLocation attribute for the imported base schema in orders.xsd is set to orders.base where I think it should be orders-base.xsd.
Comment 10 Brian Fitzpatrick 2013-11-26 10:41:01 EST
Andrej, I am also seeing the issue with the orders.xsd when I import using the most recent version of the SwitchYard tooling. This has nothing to do with the SY tooling itself and something to do with how Eclipse is validating the use of the XML Catalog element. Even if I import the catalog as provided by the quickstart into Eclipse (File->Import, XML->XML Catalog) it's not finding the order.base for the substitution group. 

This is going to require some further investigation I'm afraid.
Comment 11 Rob Cernich 2013-12-02 12:23:28 EST
The remaining issue is not related to the tooling.  As I stated above, the issue can be fixed by updating the schemaLocation attribute from orders.base to orders-base.xsd (i.e. change it to the actual schema location).
Comment 12 Brian Fitzpatrick 2013-12-02 12:27:47 EST
That's true, but then the quickstart doesn't run for me. It fails with errors.
Comment 13 Rob Cernich 2013-12-02 12:33:33 EST
You'll need to update the catalog file as well.  Or...Instead of updating the XSD, you could update the readme to tell users to add the catalog file packaged with the quickstart to their list of catalogs (preferences, XML->XML Catalog, then add a catalog entry, specifying the catalog in the xsd folder).
Comment 14 JBoss JIRA Server 2013-12-02 19:00:32 EST
Brian Fitzpatrick <bfitzpat@redhat.com> updated the status of jira SWITCHYARD-1652 to Reopened
Comment 15 JBoss JIRA Server 2013-12-02 19:00:32 EST
Brian Fitzpatrick <bfitzpat@redhat.com> made a comment on jira SWITCHYARD-1652

Reopening to address some XML validation errors
Comment 16 JBoss JIRA Server 2013-12-02 19:01:07 EST
Brian Fitzpatrick <bfitzpat@redhat.com> made a comment on jira SWITCHYARD-1652

Patch fixes the schema validation errors.
Comment 17 Andrej Podhradsky 2014-01-21 14:07:32 EST
Rob or Brian, could you describe me what's the correct workaround, please?
Comment 18 Rob Cernich 2014-01-21 14:14:47 EST
Andrej, I think you need to add src/main/resources/xsd/catalog.xml to your XML Catalog preferences (Window->Preferences..., under XML).  This will allow the Eclipse XML validator to resolve the schemaLocation, orders.base.  In other words, you need to configure Eclipse to use the same catalog file that the runtime will use during execution.  Hope that helps.
Comment 19 JBoss JIRA Server 2014-06-16 19:52:02 EDT
Keith Babo <kbabo@redhat.com> updated the status of jira SWITCHYARD-1654 to Closed
Comment 20 Douglas Palmer 2014-10-24 12:04:48 EDT
Updated the quickstart to remove errors/warnings. Added instructions to the Readme on how to configure the XML catalog in eclipse.
Comment 21 JBoss JIRA Server 2014-11-17 10:38:48 EST
Douglas Palmer <dpalmer@redhat.com> updated the status of jira SWITCHYARD-2385 to Reopened

Note You need to log in before you can comment on or make changes to this bug.