Skip to Main Content

Intelligent Advisor

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Generate class files using WSDL url and wsimport

Snehal TendulkarDec 4 2015 — edited Dec 21 2015

I'm trying to create an application in java that hits the service exposed by hub.

To create the request in java, I'm trying to generate class files using the wsdl that is created and exposed by the hub.

Steps executed:

1. Created an application in OPA.

2. Deployed it on hub (usinf deploy snapshot option on policy modeling)

3. In the deployment tab, I see the application and by clicking on it I get the wsdl url.

I try executing wsimport command on this wsdl. But it gives me the following error messages.

---------------------------------------------------------------------------------------------------

C:\******\AllFiles>wsimport http://localhost:7001/hub/determinations-server/assess/soap/generic/12.2/AttemptOne?wsdl

parsing WSDL...

[ERROR] Invalid WSDL http://localhost:7001/hub/determinations-server/assess/soap/generic/12.2/AttemptOne?wsdl, expected {http://schemas.xmlsoap.org/wsdl/}definitions found html at (line 2)

Failed to read the WSDL document: http://localhost:7001/hub/determinations-server/assess/soap/generic/12.2/AttemptOne?wsdl, because 1) could not find the document; /2) the document could not be read; 3) the root element of the document is not <wsdl:definitions>.

[ERROR] Could not find wsdl:service in the provided WSDL(s):

At least one WSDL with at least one service definition needs to be provided.

        Failed to parse the WSDL.

---------------------------------------------------------------------------------------------------

If I store the wsdl in a file on my local machine, and execute wsimport, it generates the classes just fine.

Can someone provide me with a way I can generate the classes using the wsdl url and not the local file?

Also, do I need to create a connection on the Connections tab on the hub?

Thanks in advance.

- Snehal

This post has been answered by Frank.Hampshire-Oracle on Dec 5 2015
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jan 18 2016
Added on Dec 4 2015
22 comments
10,490 views