You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@cxf.apache.org by sachin2713 <sa...@gmail.com> on 2012/12/03 14:51:46 UTC
Relative Path xsds not found while creating web service
Hello All,
I am facing below problem while exposing cxf web service using contract
first approach. My tech stack is cxf 2.4.2.
if the WSDL contains nested XSD includes with relative paths such as ../,
the path to those includes that is built from their relative path is built
incorrectly and a FileNotFoundException is produced. The generated XSD
file's path is computed from the server deployment folder location rather
than from the WSDL location on the remote machine.
<import schemaLocation="../xsd/MustTradeID.xsd" For this CXF tries
to fing xsd in WAS server profile.
Caused by: java.io.FileNotFoundException:
F:\IBM\WebSphere\AppServer\profiles\xsd\MustTradeID.xsd (The system cannot
find the path specified.)
at java.io.FileInputStream.open(Native Method)
at java.io.FileInputStream.<init>(FileInputStream.java:112)
--
View this message in context: http://cxf.547215.n5.nabble.com/Relative-Path-xsds-not-found-while-creating-web-service-tp5719571.html
Sent from the cxf-user mailing list archive at Nabble.com.
Re: Relative Path xsds not found while creating web service
Posted by sachin2713 <sa...@gmail.com>.
Yeah, wsdl and xsds are at same location and copied in an archive of
WEB-INF/lib folder.
--
View this message in context: http://cxf.547215.n5.nabble.com/Relative-Path-xsds-not-found-while-creating-web-service-tp5719571p5719702.html
Sent from the cxf-user mailing list archive at Nabble.com.
Re: Relative Path xsds not found while creating web service
Posted by Mark Streit <mc...@gmail.com>.
Have you looked at Glen Mazza's Blog articles on web services and CXF?
http://www.jroller.com/gmazza/entry/web_service_tutorial
Full list is here: http://www.jroller.com/gmazza/entry/blog_article_index
And...are the WSDL and imported XSDs in the same resource location when you
start building the application? Are they packaged in the /WEB-INF/wsdl
folder of the WAR?
Mark
On Tue, Dec 4, 2012 at 12:59 PM, sachin2713 <sa...@gmail.com> wrote:
> Hi Aki,
>
> Thanks for reply, but it's not like this, CXF is picking up wsdl from
> different location and not the app server where it's trying to find xsds.
> Looks like an issue with resolving root directory.
>
>
>
> --
> View this message in context:
> http://cxf.547215.n5.nabble.com/Relative-Path-xsds-not-found-while-creating-web-service-tp5719571p5719649.html
> Sent from the cxf-user mailing list archive at Nabble.com.
>
*
*
Re: Relative Path xsds not found while creating web service
Posted by sachin2713 <sa...@gmail.com>.
Hi Aki,
Thanks for reply, but it's not like this, CXF is picking up wsdl from
different location and not the app server where it's trying to find xsds.
Looks like an issue with resolving root directory.
--
View this message in context: http://cxf.547215.n5.nabble.com/Relative-Path-xsds-not-found-while-creating-web-service-tp5719571p5719649.html
Sent from the cxf-user mailing list archive at Nabble.com.
Re: Relative Path xsds not found while creating web service
Posted by Aki Yoshida <el...@gmail.com>.
not sure about your exact setup.
How is your WSDL read?
I suppose the schema was looked up in
F:\IBM\WebSphere\AppServer\profiles\xsd\ because your WSDL was read
from F:\IBM\WebSphere\AppServer\profiles\???\???.wsdl, no?
2012/12/3 sachin2713 <sa...@gmail.com>:
> F:\IBM\WebSphere\AppServer\profiles\xsd\MustTradeID.xsd (The system cannot