IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
Expand all | Collapse all

Calling soap webservice using pub.client:http

  • 1.  Calling soap webservice using pub.client:http

    Posted Wed July 27, 2022 05:27 AM

    IS 10.5

    full version

    I am calling a soap webservice by giving its wsdl url in pub.client.http service and using post method. The issue is that I am not getting any error after running the service and i am getting everything ok but the output i.e. need to generate audio.mp3 file is not happening in the file location on the server. However when I am calling the same soap webservice from SOAPUI it is working fine and the audio.mp3 file is creating in the specified location on the server.


    #Integration-Server-and-ESB
    #webMethods


  • 2.  RE: Calling soap webservice using pub.client:http

    Posted Wed July 27, 2022 08:45 AM

    Hi Azhar,

    you will have to create a Consumer WSD by importing the WSDL in Designer first.
    After that you can invoke this Consumer service.

    Regards,
    Holger


    #Integration-Server-and-ESB
    #webMethods


  • 3.  RE: Calling soap webservice using pub.client:http

    Posted Wed July 27, 2022 01:55 PM

    Hi, Holger,
    Thanks for the response. So according to you, i need to use the connector in a flow service?
    But I need to call the webservice using pub.client:http. I am specifying the url, ‘methos’: post, ‘loadas’:stream.


    and the result after running this http_invoke is in the image below:


    #webMethods
    #Integration-Server-and-ESB


  • 4.  RE: Calling soap webservice using pub.client:http

    Posted Thu July 28, 2022 04:25 AM

    You can consume a SOAP WS via HTTP, a consumer object is not needed - I’ll respond later today with more details.

    However, can you ensure that this target WS is working as expected in the first place?
    Does it create the file, when you are NOT invoking via HTTP?

    KM


    #Integration-Server-and-ESB
    #webMethods


  • 5.  RE: Calling soap webservice using pub.client:http

    Posted Thu July 28, 2022 06:22 AM

    thanks KM
    Yes, the target WS is working fine and the file is created everytime I am running the service.


    #webMethods
    #Integration-Server-and-ESB


  • 6.  RE: Calling soap webservice using pub.client:http

    Posted Thu July 28, 2022 07:45 AM

    You said that you’re posting to the WSDL URL, but you must be using the Endpoint URL.
    You can get the endpoint URL from the WSDL content, or you can import the WSDL on SOAP UI and it will show you the URL that you must be posting to.

    KM


    #webMethods
    #Integration-Server-and-ESB


  • 7.  RE: Calling soap webservice using pub.client:http

    Posted Thu July 28, 2022 09:06 AM

    Yes, I am using the Endpoint URL after importing on SOAPUI, still the file is not creating and the status is 200 coming. I have tried with the provide wsdl url and also with cosumer url too.


    #Integration-Server-and-ESB
    #webMethods


  • 8.  RE: Calling soap webservice using pub.client:http

    Posted Thu July 28, 2022 09:21 AM

    A “200 OK” indicates that the service executed without a failure, but it doesn’t mean that the service performed the functional action. Perhaps there’s an exception that’s being handled in the catch and not propagated to indicate failure, so it’s treated as a successful “execution”.

    Use the “Save pipeline” option, and see if the inputs are being populated as expected, when you restore it.

    Post the actual Endpoint URL as well here - I’d like to see the second half of it (the screenshot shows the first half).

    KM


    #webMethods
    #Integration-Server-and-ESB


  • 9.  RE: Calling soap webservice using pub.client:http

    Posted Thu July 28, 2022 09:41 AM

    Hi KM, I am attaching the word doc in which I have specify each step. Please check it.
    Steps.docx (373.2 KB)

    And when I am running http WS while putting base64Decode WS in save pipeline mode and then checking base64… in restorepipeline in debug mode then no data is coming.


    #Integration-Server-and-ESB
    #webMethods


  • 10.  RE: Calling soap webservice using pub.client:http

    Posted Thu July 28, 2022 09:56 AM

    That’s what I thought because I saw a “?” in your screenshot above - you are still using the WSDL URL (ends with ?WSDL) and not the Endpoint URL.

    Open SOAP UI, create a SOAP project, provide the WSDL URL.
    Once you do, it will give generate the project and you a request, with a longer URL (without “?WSDL”) - that’s the one you must use.

    Post a screenshot after the import, if you need guidance.

    KM


    #webMethods
    #Integration-Server-and-ESB


  • 11.  RE: Calling soap webservice using pub.client:http



  • 12.  RE: Calling soap webservice using pub.client:http

    Posted Thu July 28, 2022 10:16 AM

    That’s the correct URL (i.e., Endpoint URL).

    You are not setting Headers in your HTTP invocation. When you’re invoking a WS via HTTP, the IS doesn’t automatically know which WSD Operation you’re invoking (even if there’s only 1 Operation on the WSD).

    Pass a Header variable named “SOAPAction” - the value for this variable will be available in the WSDL file. Open the WSDL URL in a browser and look for SOAPAction in it.

    I’m unable to recollect some specifics or provide you an example, so you’ll have to perform trials - there’s plenty of info available online on what Headers to set while invoking a WSD via HTTP.

    KM


    #webMethods
    #Integration-Server-and-ESB


  • 13.  RE: Calling soap webservice using pub.client:http

    Posted Thu July 28, 2022 10:31 AM


    Now I have used SoapAction also as you said but the issue still coming. However I am trying to find out about headers part on the internet as you said.
    Please check my data>>args>>inputfile,loadAs, outputfile(variables) are in correct way?
    Thanks


    #webMethods
    #Integration-Server-and-ESB


  • 14.  RE: Calling soap webservice using pub.client:http

    Posted Thu July 28, 2022 11:50 AM

    Do follow what I’ve mentioned about using save and restore pipeline, to see if your variables are reaching the target service, in the way it expects.
    It’s not possible to say if this correct, because the target (file creation) service may have the inputs structured/named differently and the mapping may be off.

    KM


    #Integration-Server-and-ESB
    #webMethods