Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Web Tools Project (WTP) » Can Eclipse xsd / wsdl editors use a jax-ws-catalog.xml file?
Can Eclipse xsd / wsdl editors use a jax-ws-catalog.xml file? [message #533263] Wed, 12 May 2010 15:03 Go to next message
Dean Schulze is currently offline Dean Schulze
Messages: 24
Registered: July 2009
Junior Member
I have wsdl and xsd files that use URLs for the schemaLocation="..." attribute in <xsd:import .../> statements. I want to resolve those <xsd:import /> statements to local files (since the xsds aren't actually deployed on the URLs) so I am using a jax-ws-catalog.xml file.

Eclipse shows errors like:

src-resolve: Cannot resolve the name 'common:DeviceIDFilter' to a(n) 'type definition' component

Is there a way to tell Eclipse to use the jax-ws-catalog.xml file to resolve the URLs to local files?

Thanks.
Re: Can Eclipse xsd / wsdl editors use a jax-ws-catalog.xml file? [message #533274 is a reply to message #533263] Wed, 12 May 2010 16:48 Go to previous messageGo to next message
Valentin is currently offline Valentin
Messages: 36
Registered: July 2009
Member
Hi Dean, what is the format of jax-ws-catalog.xml? Is it an Oasis catalog?
http://www.oasis-open.org/committees/download.php/14809/xml- catalogs.html
If so, then you should be able to use it to instruct tools in the workspace
how to resolve the locations. See Window->Preferences->XML->XML Catalog,
specifically perhaps you can use it as a chained catalog (next catalog).

Valentin


"Dean Schulze" <dean_w_schulze@yahoo.com> wrote in message
news:hseu2m$k88$1@build.eclipse.org...
>I have wsdl and xsd files that use URLs for the schemaLocation="..."
>attribute in <xsd:import .../> statements. I want to resolve those
><xsd:import /> statements to local files (since the xsds aren't actually
>deployed on the URLs) so I am using a jax-ws-catalog.xml file.
> Eclipse shows errors like:
>
> src-resolve: Cannot resolve the name 'common:DeviceIDFilter' to a(n) 'type
> definition' component
>
> Is there a way to tell Eclipse to use the jax-ws-catalog.xml file to
> resolve the URLs to local files?
>
> Thanks.
>
Re: Can Eclipse xsd / wsdl editors use a jax-ws-catalog.xml file? [message #533453 is a reply to message #533274] Thu, 13 May 2010 20:24 Go to previous messageGo to next message
Dean Schulze is currently offline Dean Schulze
Messages: 24
Registered: July 2009
Junior Member
Thanks Valentin.

It is an OASIS catalog. I had a deliverable to get out today. I'll give it a try tomorrow and follow up back here on how it worked.
Re: Can Eclipse xsd / wsdl editors use a jax-ws-catalog.xml file? [message #533578 is a reply to message #533274] Fri, 14 May 2010 11:34 Go to previous messageGo to next message
Dean Schulze is currently offline Dean Schulze
Messages: 24
Registered: July 2009
Junior Member
This approach requires that I Add the entries from my jax-ws-catalog.xml file to User Specified Entries rather than using the jax-ws-catalog.xml file itself.

I guess there's no point in using the jax-ws-catalog.xml file itself outside of the .war file anyway.

Is there some way to verify if the jax-ws-catalog.xml file resolves resources correctly (or if those resources are where they need to be) in the .war file?

Thanks.
Re: Can Eclipse xsd / wsdl editors use a jax-ws-catalog.xml file? [message #533590 is a reply to message #533578] Fri, 14 May 2010 12:09 Go to previous messageGo to next message
Valentin is currently offline Valentin
Messages: 36
Registered: July 2009
Member
I'll let someone better qualified to talk about URI resolution inside a .war
file.

As for the workspace XML Catalog, in the Add XML Catalog Element dialog, did
you click in the left side navigation bar on Next Catalog? That should allow
you to link your catalog file as is in the chain of XML catalogs used in the
workspace.

"Dean Schulze" <dean_w_schulze@yahoo.com> wrote in message
news:hsjqiv$6u6$1@build.eclipse.org...
> This approach requires that I Add the entries from my jax-ws-catalog.xml
> file to User Specified Entries rather than using the jax-ws-catalog.xml
> file itself.
>
> I guess there's no point in using the jax-ws-catalog.xml file itself
> outside of the .war file anyway.
>
> Is there some way to verify if the jax-ws-catalog.xml file resolves
> resources correctly (or if those resources are where they need to be) in
> the .war file?
>
> Thanks.
>
Re: Can Eclipse xsd / wsdl editors use a jax-ws-catalog.xml file? [message #533629 is a reply to message #533590] Fri, 14 May 2010 15:45 Go to previous messageGo to next message
Dean Schulze is currently offline Dean Schulze
Messages: 24
Registered: July 2009
Junior Member
Thanks. That worked - sort of.

I notice now that when I change the schemaLocation in the wsdl and validate it shows an error. If I modify the jax-ws-catalog.xml so that the systemId is different from the schemaLocation it still passes validation when it should fail.

It appears the the XML Catalog is caching the jax-ws-catalog.xml file instead of reading it on validation each time.

Is this how it is supposed to work?
Re: Can Eclipse xsd / wsdl editors use a jax-ws-catalog.xml file? [message #534624 is a reply to message #533629] Wed, 19 May 2010 12:39 Go to previous message
Gabriel Indik is currently offline Gabriel Indik
Messages: 16
Registered: July 2009
Junior Member
Dean Schulze wrote on Fri, 14 May 2010 15:45

It appears the the XML Catalog is caching the jax-ws-catalog.xml file instead of reading it on validation each time.
Is this how it is supposed to work?



Hi Dean,
That is correct, the entries in the catalog are cached in memory so the XML file doesn't have to be parsed every time a document is resolved. Currently there doesn't seem to be a way to re-load the catalog entries other than removing and adding them back the catalog. I opened Bug 313571 to address this.
Previous Topic:How to set up a JPA project to use Maven?
Next Topic:Create eclipse debugger for StructuredTextEditor.
Goto Forum:
  


Current Time: Thu Jul 31 23:44:33 EDT 2014

Powered by FUDForum. Page generated in 0.01638 seconds