Skip to main content
Announcements
SYSTEM MAINTENANCE: Thurs., Sept. 19, 1 AM ET, Platform will be unavailable for approx. 60 minutes.
cancel
Showing results for 
Search instead for 
Did you mean: 
anna_talend
Contributor
Contributor

tESBConsumer

Hi,
I tried to consume a soap-Webservice from German DHL. But I always get an error. In SoapUi it works, but not in Talend. Maybe someone can help me.
Thank you!

My Job is simple:
tXMLFileInput -> tESBConsumer -> tLogRow
tXMLFileInput reads an Example-XML, the same file I used with SoapUI
ErrorMessage:
Starte Job SoapTestDHL am 13:33 17/05/2016.
connecting to socket on port 3778
connected
: org.apache.cxf.wsdl.service.factory.ReflectionServiceFactoryBean - No method was found for the WSDL operation {}getManifestDD.
: org.apache.cxf.wsdl.service.factory.ReflectionServiceFactoryBean - No method was found for the WSDL operation {}doManifestTD.
: org.apache.cxf.wsdl.service.factory.ReflectionServiceFactoryBean - No method was found for the WSDL operation {}bookPickup. : org.apache.cxf.wsdl.service.factory.ReflectionServiceFactoryBean - No method was found for the WSDL operation {}crea

To see the whole post, download it here
Labels (5)
4 Replies
Anonymous
Not applicable

Hi,
Have you tried to use  tsoap component to call your SOAP web service?
The work flow should be:tfileinputxml-->tsoap-->tlogrow
Please see the related scenario in component reference:TalendHelpCenter:tSOAP
Best regards
Sabrina
anna_talend
Contributor
Contributor
Author

Hi Sabrina,
I tried to use tsoap component. But I need basic Http authentication . I don't know what kind of authentication tsoap uses.
The Error-Message was
connecting to socket on port 3956
connected
Mai 18, 2016 10:11:53 AM com.sun.xml.internal.messaging.saaj.client.p2p.HttpSOAPConnection post
SCHWERWIEGEND: SAAJ0008: Bad Response; Unauthorized
Exception in component tSOAP_1
com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: Bad response: (401Unauthorized
    at com.sun.xml.internal.messaging.saaj.client.p2p.HttpSOAPConnection.call(Unknown Source)
    at org.talend.soap.SOAPUtil.invokeSOAP(SOAPUtil.java:113)
    at vaho_6.soaptestdhl_0_1.SoapTestDHL.tFileInputXML_4Process(SoapTestDHL.java:859)
    at vaho_6.soaptestdhl_0_1.SoapTestDHL.runJobInTOS(SoapTestDHL.java:1262)
    at vaho_6.soaptestdhl_0_1.SoapTestDHL.main(SoapTestDHL.java:1119)
Caused by: com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: Bad response: (401Unauthorized
    at com.sun.xml.internal.messaging.saaj.client.p2p.HttpSOAPConnection.post(Unknown Source)
    ... 5 more
CAUSE:
com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: Bad response: (401Unauthorized
    at com.sun.xml.internal.messaging.saaj.client.p2p.HttpSOAPConnection.post(Unknown Source)
disconnected
    at com.sun.xml.internal.messaging.saaj.client.p2p.HttpSOAPConnection.call(Unknown Source)
    at org.talend.soap.SOAPUtil.invokeSOAP(SOAPUtil.java:113)
    at vaho_6.soaptestdhl_0_1.SoapTestDHL.tFileInputXML_4Process(SoapTestDHL.java:859)
    at vaho_6.soaptestdhl_0_1.SoapTestDHL.runJobInTOS(SoapTestDHL.java:1262)
    at vaho_6.soaptestdhl_0_1.SoapTestDHL.main(SoapTestDHL.java:1119)
CAUSE:
com.sun.xml.internal.messaging.saaj.SOAPExceptionImpl: Bad response: (401Unauthorized
    at com.sun.xml.internal.messaging.saaj.client.p2p.HttpSOAPConnection.post(Unknown Source)
    at com.sun.xml.internal.messaging.saaj.client.p2p.HttpSOAPConnection.call(Unknown Source)
    at org.talend.soap.SOAPUtil.invokeSOAP(SOAPUtil.java:113)
    at vaho_6.soaptestdhl_0_1.SoapTestDHL.tFileInputXML_4Process(SoapTestDHL.java:859)
    at vaho_6.soaptestdhl_0_1.SoapTestDHL.runJobInTOS(SoapTestDHL.java:1262)
    at vaho_6.soaptestdhl_0_1.SoapTestDHL.main(SoapTestDHL.java:1119)
Job SoapTestDHL endet am 10:11 18/05/2016.
The manuel says:
Applications that call the DHL APIs must authenticate themselves at the Customer Integration Gateway (CIG). This authentication serves to identify the calling application and is independent of the additional authentication required to use the customer-related services of DHL PAKET, i.e. the DHL business customer shipping and private customer shipping APIs, etc. documented here.
The application authentication at the CIG is based on HTTP Basic Authentication specified in RFC 2617.
To use the business customer shipping test API, you will first need CIG authentication of your application in test mode.
The following credentials must also then be given in the web service:
User: geschaeftskunden_apiSignature: Dhl_ep_test1EKP: 5000000000
The user credentials must be entered in the SOAP header in "cis:Authentification":
<soapenv:Envelope xmlns:soapenv=""
 xmlns:cis=""
 xmlns:de="">
 <soapenv:Header>
 <cis:Authentification>
 <cis:user>geschaeftskunden_api</cis:user>
 <cis:signature>Dhl_ep_test1<cis:signature>
 <cis:type>0</cis:type>
 </cis:Authentification>
 </soapenv:Header>
 <soapenv:Body>
 ...

0683p000009ME5x.png
BderPan
Contributor III
Contributor III

@anna.talend

 

How did you solved the problem with the BasicAuth? 

anna_talend
Contributor
Contributor
Author

Hi @ris.tan,

 

yes, I solved the problem. Two years ago...

 

The solution was to separate body and header. The input schema of tESBConsumer is payload(Document) and headers (Document).

Build payload and header separately and unite them with tmap:

 

payload (document) - tmap - tESBConsumer - response

                                        |

                           header (document)