Author |
Message
|
bjr149 |
Posted: Fri Mar 05, 2010 6:18 am Post subject: Using WMB as a SOAP Provider |
|
|
Novice
Joined: 03 Mar 2010 Posts: 22
|
Im doing so research using WMB. Im looking into the SOAP Nodes now. I imported the SOAPNodesSample from the help menu for the Broker Toolkit and deployed it to the broker. Im having an issue figuring out what the actual URL would be to post to the webservice.
The example is using a SOAP Input node. The Path Suffix for URL = "/acmeOrders/WADDR/ProcessOrders". So I tried the URL http://localhost:7800/acmeOrders/WADDR/ProcessOrders?WSDL and no WSDL comes up. So Im not sure how to access or call the web service hosted on the broker. If I tried it without the WSDL nothing still comes up. Am I using the wrong URL?[/img] |
|
Back to top |
|
 |
Vitor |
Posted: Fri Mar 05, 2010 6:24 am Post subject: Re: Using WMB as a SOAP Provider |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
bjr149 wrote: |
If I tried it without the WSDL nothing still comes up. Am I using the wrong URL?[/img] |
No, but you might not have completed the set up. Ensure the WMB listener is running and if so, run a user trace to see what WMB is doing. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
bjr149 |
Posted: Fri Mar 05, 2010 7:05 am Post subject: |
|
|
Novice
Joined: 03 Mar 2010 Posts: 22
|
It seems like it is up and running. If i punch in http://localhost:7800/acmeOrders/WADDR/ProcessOrders
I get a "XML page cannot be displayed" IE Error. If I try other ports i get a pge cannot be displayed.
What do you mean setup the user trace to see what WMB is doing?
Where does this proxyservlet come into play? Is this just if you want external people to access the webservices through a different URL. Then they won't know the actual URL?
Thanks. |
|
Back to top |
|
 |
Vitor |
Posted: Fri Mar 05, 2010 7:11 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
Of course you get that. Have you read the documentation associated with the sample to see what it's actually doing? As opposed to what you seem to be assuming it's doing?
bjr149 wrote: |
What do you mean setup the user trace to see what WMB is doing? |
This is basic WMB troubleshooting and described in the manual much better than I could ever do here.
bjr149 wrote: |
Where does this proxyservlet come into play? Is this just if you want external people to access the webservices through a different URL. Then they won't know the actual URL? |
You've made a couple of posts over the last few days on WMB as you research. Have you considered buying some consultancy days from an experienced WMB person? They could get you up and running, and also provide some input into possible uses of WMB to meet your specific requirements.
It's going to be faster and more productive than feeling your way through a complex product with nothing to guide you but the manuals, some samples and a bunch of volunteers off the Internet.  _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
Svp |
Posted: Fri Mar 05, 2010 7:22 am Post subject: |
|
|
Apprentice
Joined: 18 Feb 2010 Posts: 40
|
Use SOAP UI Tool to send a message. You cannot do that using your IE. |
|
Back to top |
|
 |
bjr149 |
Posted: Fri Mar 05, 2010 7:25 am Post subject: |
|
|
Novice
Joined: 03 Mar 2010 Posts: 22
|
I am using SOAP UI. THe problem is I can't acquire the WSDL using the URL. This is why it doesn't seem to be the right URL. |
|
Back to top |
|
 |
Vitor |
Posted: Fri Mar 05, 2010 7:30 am Post subject: |
|
|
 Grand High Poobah
Joined: 11 Nov 2005 Posts: 26093 Location: Texas, USA
|
bjr149 wrote: |
THe problem is I can't acquire the WSDL using the URL. |
The problem is you still haven't followed my advice and read the documentation. Then you'd know that you can't acquire the WSDL that way. _________________ Honesty is the best policy.
Insanity is the best defence. |
|
Back to top |
|
 |
Svp |
Posted: Fri Mar 05, 2010 7:31 am Post subject: |
|
|
Apprentice
Joined: 18 Feb 2010 Posts: 40
|
You have to import WSDL file to your SOAP UI. Once you import it will automatically generates the URL and the message you want to send. |
|
Back to top |
|
 |
harish_td |
Posted: Sun Mar 07, 2010 5:54 pm Post subject: |
|
|
Master
Joined: 13 Feb 2006 Posts: 236
|
Here's what i would do
1. Check whether port 7800 is in use by any other process
Code: |
C:\>netstat -an | grep 7800
|
2. After the flow is deployed, the HTTP listener would start listening to your requests.
Code: |
C:\>netstat -an | grep 7800
TCP 0.0.0.0:7800 0.0.0.0:0 LISTENING
|
3. If the above is running fine, then ensure that your windows firewall is not blocking any requests on port 7800.
4. Use soapUI to hit the complete URL, switch to Raw view within the response tab. This should give you the HTTP Reason code that would help you to further isolate whether or not you are getting any responses.
Just my 0.02$ |
|
Back to top |
|
 |
goffinf |
Posted: Tue Mar 09, 2010 1:32 am Post subject: |
|
|
Chevalier
Joined: 05 Nov 2005 Posts: 401
|
grep .... ? .... on Windows ?? |
|
Back to top |
|
 |
smdavies99 |
Posted: Tue Mar 09, 2010 3:36 am Post subject: |
|
|
 Jedi Council
Joined: 10 Feb 2003 Posts: 6076 Location: Somewhere over the Rainbow this side of Never-never land.
|
goffinf wrote: |
grep .... ? .... on Windows ?? |
Yep. Just google for it. I have windows copies of grep.exe, md5sum.exe & a few other nice to have utilities from Unix/Linux land as well on most of my Few remaining Windows systems.
You could also install Windows Services for Unix. _________________ WMQ User since 1999
MQSI/WBI/WMB/'Thingy' User since 2002
Linux user since 1995
Every time you reinvent the wheel the more square it gets (anon). If in doubt think and investigate before you ask silly questions. |
|
Back to top |
|
 |
bjr149 |
Posted: Mon Mar 15, 2010 5:09 am Post subject: |
|
|
Novice
Joined: 03 Mar 2010 Posts: 22
|
OK. Im back to playing with this. Still having issues. I took the most basic WSDL from the internet. It basically is a lame hello world webservice. I don't care about the content I am just figuring out how to configure a SOAP input. I created a simple message flow with SOAPInput, Trace, SOAPReply. Here is the WSDL I configured the SOAPInput node with.
Code: |
<?xml version="1.0" encoding="UTF-8"?>
<definitions xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://www.ecerami.com/wsdl/HelloService.wsdl" xmlns:xsd="http://www.w3.org/2001/XMLSchema" name="HelloService" targetNamespace="http://www.ecerami.com/wsdl/HelloService.wsdl">
<documentation>
<appinfo source="WMQI_APPINFO">
<MRWSDLAppInfo imported="true">
<binding hasEncoding="true" imported="true" name="Hello_Binding" originalBindingStyle="rpc"/>
<generatedMXSD location="test.mxsd"/>
</MRWSDLAppInfo>
</appinfo>
</documentation>
<message name="SayHelloRequest">
<part name="firstName" type="xsd:string"/>
</message>
<message name="SayHelloResponse">
<part name="greeting" type="xsd:string"/>
</message>
<portType name="Hello_PortType">
<operation name="sayHello">
<input message="tns:SayHelloRequest"/>
<output message="tns:SayHelloResponse"/>
</operation>
</portType>
<binding name="Hello_Binding" type="tns:Hello_PortType">
<soap:binding style="rpc" transport="http://schemas.xmlsoap.org/soap/http"/>
<operation name="sayHello">
<soap:operation soapAction="sayHello"/>
<input>
<soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:examples:helloservice" use="encoded"/>
</input>
<output>
<soap:body encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" namespace="urn:examples:helloservice" use="encoded"/>
</output>
</operation>
</binding>
<service name="Hello_Service">
<documentation>WSDL File for HelloService</documentation>
<port binding="tns:Hello_Binding" name="Hello_Port">
<soap:address location="http://localhost:7800/SOAPInput1/test"/>
</port>
</service>
</definitions>
|
For the Path suffix for URL In the SOAPInput node i have.
I used the WSDL above to import into SOAPUI. I had soapUI create a request for me which is below.
Code: |
<soapenv:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:urn="urn:examples:helloservice">
<soapenv:Header/>
<soapenv:Body>
<urn:sayHello soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<firstName xsi:type="xsd:string">x</firstName>
</urn:sayHello>
</soapenv:Body>
</soapenv:Envelope>
|
When I submit it I get a weird parsing error. It seems like it is hitting the message flow because the XML error references the msgflow. Any ideas on the error?
Code: |
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<soapenv:Fault>
<faultcode>soapenv:Server</faultcode>
<faultstring>BIP3113E: Exception detected in message flow SOAPTest1Flow.SOAP Input (broker STUDENT01)</faultstring>
<detail>
<Text>BIP2230E: Error detected whilst processing a message in node 'SOAPTest1Flow.SOAP Reply'.
The message broker detected an error whilst processing a message in node 'SOAPTest1Flow.SOAP Reply'. An exception has been thrown to cut short the processing of the message.
See the following messages for details of the error. : F:\build\S610_P\src\WebServices\WSLibrary\ImbSOAPReplyNode.cpp: 921: ImbSOAPReplyNode::evaluate: ComIbmSOAPReplyNode: SOAPTest1Flow#FCMComposite_1_2
BIP3614E: A SOAP logical tree cannot be built from the message bitstream.
The bitstream is not a valid Web service message.
Review further error messages for an indication to the cause of the error. : F:\build\S610_P\src\WebServices\WSLibrary\ImbSOAPParser.cpp: 1978: ImbSOAPParser::createSoapShapedTree: :
BIP5009E: XML Parsing Errors have occurred.
Errors have occurred during parsing of XML.
Review further error messages for an indication to the cause of the errors. : F:\build\S610_P\src\MTI\MTIforBroker\GenXmlParser4\ImbXMLNSCParser.cpp: 953: ImbXMLNSCParser::parseRightSibling: :
BIP5025E: XML schema validation error ''cvc-complex-type.2.4.e: Unexpected element. Element "urn:sayHello" is not one of the choices.'' on line '4' column '87' when parsing element ''/XMLNSC/http://schemas.xmlsoap.org/soap/envelope/:Envelope/http://schemas.xmlsoap.org/soap/envelope/:Body''.
Internal error codes: 5008, 2.
This error was reported by the XMLNSC parser. The XML document being parsed is not valid according to the message definitions in the message set.
The XML document has violated the rules expressed in the message definition files in the message set. : F:\build\S610_P\src\MTI\MTIforBroker\GenXmlParser4\ImbXMLNSCDocHandler.cpp: 550: ImbXMLNSCDocHandler::handleParseErrors: ComIbmSOAPInputNode: SOAPTest1Flow#FCMComposite_1_1</Text>
</detail>
</soapenv:Fault>
</soapenv:Body>
</soapenv:Envelope>
|
|
|
Back to top |
|
 |
harish_td |
Posted: Mon Mar 15, 2010 10:26 pm Post subject: |
|
|
Master
Joined: 13 Feb 2006 Posts: 236
|
I managed to hit the same error as you are. However i recreated the WSDL based on what you are trying to do. Please use this WSDL for your testing and let me know if it helps you understand the SOAP Nodes.
I will continue to look at what is wrong with your original WSDL and post back if i have any findings.
Code: |
<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions name="Hello" targetNamespace="http://www.example.org/Hello/"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:tns="http://www.example.org/Hello/"
xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<wsdl:types>
<xsd:schema targetNamespace="http://www.example.org/Hello/">
<xsd:element name="sayHello">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="firstName" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="sayHelloResponse">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="greetings" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:schema>
</wsdl:types>
<wsdl:message name="sayHelloRequest">
<wsdl:part element="tns:sayHello" name="sayHello"/>
</wsdl:message>
<wsdl:message name="sayHelloResponse">
<wsdl:part element="tns:sayHelloResponse" name="sayHelloResponse"/>
</wsdl:message>
<wsdl:portType name="Hello">
<wsdl:operation name="sayHello">
<wsdl:input message="tns:sayHelloRequest"/>
<wsdl:output message="tns:sayHelloResponse"/>
</wsdl:operation>
</wsdl:portType>
<wsdl:binding name="HelloSOAP" type="tns:Hello">
<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
<wsdl:operation name="sayHello">
<soap:operation soapAction="http://www.example.org/Hello/sayHello"/>
<wsdl:input>
<soap:body use="literal"/>
</wsdl:input>
<wsdl:output>
<soap:body use="literal"/>
</wsdl:output>
</wsdl:operation>
</wsdl:binding>
<wsdl:service name="Hello">
<wsdl:port binding="tns:HelloSOAP" name="HelloSOAP">
<soap:address location="http://www.example.org/"/>
</wsdl:port>
</wsdl:service>
</wsdl:definitions>
|
|
|
Back to top |
|
 |
mqceries |
Posted: Wed Dec 07, 2011 2:50 pm Post subject: |
|
|
 Acolyte
Joined: 02 Dec 2011 Posts: 70
|
|
Back to top |
|
 |
lancelotlinc |
Posted: Wed Dec 07, 2011 3:11 pm Post subject: |
|
|
 Jedi Knight
Joined: 22 Mar 2010 Posts: 4941 Location: Bloomington, IL USA
|
mqceries wrote: |
any solution yet guys. |
SOAP nodes work very well. If you are having difficulty, please post your trace output in a new thread. _________________ http://leanpub.com/IIB_Tips_and_Tricks
Save $20: Coupon Code: MQSERIES_READER |
|
Back to top |
|
 |
|