Problem consuming SAP-XI webservice |
|
The WSDL looks like this:
I don't see "pos_reservas" type as an array..
Maybe that would solve my problem? Because i could use something like that (applying to my parameters ofc):
|
||||||||||||||||||
|
|
I'm also tried sending the whole XML genrated "by hand", doing that way:
The message is arriving to XI Server and seems well formed but it's giving me that error: [code] Notice: Undefined property: nusoap_client::$operation in F:\recursos\lib\nusoap.php on line 7519 Result Array ( [faultcode] => SOAP:Server [faultstring] => Server Error [detail] => Array ( [SystemError] => Array ( [context] => XIAdapter [code] => ADAPTER.JAVA_EXCEPTION [text] => com.sap.aii.af.ra.ms.api.DeliveryException: Application:EXCEPTION_DURING_EXECUTE: at com.sap.aii.adapter.xi.ms.XIEventHandler.onTransmit(XIEventHandler.java:455) at com.sap.aii.af.ra.ms.impl.core.queue.consumer.CallConsumer.onMessage(CallConsumer.java:134) at com.sap.aii.af.ra.ms.impl.core.queue.Queue.run(Queue.java:917) at com.sap.aii.af.ra.ms.runtime.MSWorkWrapper.run(MSWorkWrapper.java:56) at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37) at java.security.AccessController.doPrivileged(AccessController.java:207) at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:102) at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:172) ) ) ) Request POST /XISOAPAdapter/MessageServlet?channel=:BSANET_DEV:bsanet_CrearReserva_SOAP_Client&version=3.0 HTTP/1.0 Host: benelus:50100 User-Agent: NuSOAP/0.7.3 (1.114) Content-Type: text/xml; charset=ISO-8859-1 SOAPAction: "os_ReservaMaterialCrear" Authorization: Basic eGlfYnNhbmV0OnhpX2JzYW5ldA== Content-Length: 905 <?xml version="1.0" encoding="ISO-8859-1"?><SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"><SOAP-ENV:Body><soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:urn="urn:bsa:bsanet"><soapenv:Header/><soapenv:Body><urn:CrearReserva><usuario>JORDI</usuario><sistema>BSANET</sistema><destinatario>PERE</destinatario><pos_reservas><centro_coste>1EMH330404</centro_coste><material>10000485</material><almacen>MAGC</almacen><cantidad>123</cantidad></pos_reservas><pos_reservas><centro_coste>1EMH330404</centro_coste><material>10000486</material><almacen>MAGC</almacen><cantidad>456</cantidad></pos_reservas></urn:CrearReserva></soapenv:Body></soapenv:Envelope></SOAP-ENV:Body></SOAP-ENV:Envelope> Response HTTP/1.1 500 Internal Server Error Connection: close Set-Cookie: JSESSIONID=(benelus_XID_01)ID1232314650DB11656244804724496146End; Version=1; Path=/ Set-Cookie: saplb_*=(benelus_XID_01)18594450; Version=1; Path=/ Server: SAP J2EE Engine/7.00 Content-Type: text/xml; charset=utf-8 Date: Fri, 28 Nov 2008 13:13:27 GMT <?xml version='1.0'?> <!-- see the documentation --> <SOAP:Envelope xmlns:SOAP='http://schemas.xmlsoap.org/soap/envelope/'> <SOAP:Body> <SOAP:Fault> <faultcode>SOAP:Server</faultcode> <faultstring>Server Error</faultstring> <detail> <s:SystemError xmlns:s='http://sap.com/xi/WebService/xi2.0'> <context>XIAdapter</context> <code>ADAPTER.JAVA_EXCEPTION</code> <text><![CDATA[ com.sap.aii.af.ra.ms.api.DeliveryException: Application:EXCEPTION_DURING_EXECUTE: at com.sap.aii.adapter.xi.ms.XIEventHandler.onTransmit(XIEventHandler.java:455) at com.sap.aii.af.ra.ms.impl.core.queue.consumer.CallConsumer.onMessage(CallConsumer.java:134) at com.sap.aii.af.ra.ms.impl.core.queue.Queue.run(Queue.java:917) at com.sap.aii.af.ra.ms.runtime.MSWorkWrapper.run(MSWorkWrapper.java:56) at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37) at java.security.AccessController.doPrivileged(AccessController.java:207) at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:102) at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:172) ]]></text> </s:SystemError> </detail> </SOAP:Fault> </SOAP:Body> </SOAP:Envelope> Debug 2008-11-28 14:15:41.102825 nusoap_client: ctor wsdl=1 timeout=0 response_timeout=30 endpoint=string(117) "http://benelus:50100/XISOAPAdapter/MessageServlet?channel=:BSANET_DEV:bsanet_CrearReserva_SOAP_Client&version=3.0" 2008-11-28 14:15:41.103175 nusoap_client: will use lazy evaluation of wsdl from http://benelus:50100/XISOAPAdapter/MessageServlet?channel=:BSANET_DEV:bsanet_CrearReserva_SOAP_Client&version=3.0 2008-11-28 14:15:41.103419 nusoap_client: setCredentials username=xi_bsanet authtype=basic certRequest= array(0) { } 2008-11-28 14:15:41.103669 nusoap_client: setUseCURL(0) 2008-11-28 14:15:41.103926 nusoap_client: In serializeEnvelope length=575 body (max 1000 characters)=<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:urn="urn:bsa:bsanet"><soapenv:Header/><soapenv:Body><urn:CrearReserva><usuario>JORDI</usuario><sistema>BSANET</sistema><destinatario>PERE</destinatario><pos_reservas><centro_coste>1EMH330404</centro_coste><material>10000485</material><almacen>MAGC</almacen><cantidad>123</cantidad></pos_reservas><pos_reservas><centro_coste>1EMH330404</centro_coste><material>10000486</material><almacen>MAGC</almacen><cantidad>456</cantidad></pos_reservas></urn:CrearReserva></soapenv:Body></soapenv:Envelope> style=document use=literal encodingStyle= 2008-11-28 14:15:41.104158 nusoap_client: headers: string(0) "" 2008-11-28 14:15:41.104493 nusoap_client: namespaces: array(0) { } 2008-11-28 14:15:41.105125 nusoap_client: transporting via HTTP 2008-11-28 14:15:41.109288 nusoap_client: sending message, length=905 2008-11-28 14:15:41.105733 soap_transport_http: ctor url=http://benelus:50100/XISOAPAdapter/MessageServlet?channel=:BSANET_DEV:bsanet_CrearReserva_SOAP_Client&version=3.0 use_curl=0 curl_options: array(0) { } 2008-11-28 14:15:41.106113 soap_transport_http: parsed URL scheme = http 2008-11-28 14:15:41.106353 soap_transport_http: parsed URL host = benelus 2008-11-28 14:15:41.106652 soap_transport_http: parsed URL port = 50100 2008-11-28 14:15:41.106886 soap_transport_http: parsed URL path = /XISOAPAdapter/MessageServlet 2008-11-28 14:15:41.107117 soap_transport_http: parsed URL query = channel=:BSANET_DEV:bsanet_CrearReserva_SOAP_Client&version=3.0 2008-11-28 14:15:41.107367 soap_transport_http: set header Host: benelus:50100 2008-11-28 14:15:41.107689 soap_transport_http: set header User-Agent: NuSOAP/0.7.3 (1.114) 2008-11-28 14:15:41.107946 soap_transport_http: set header Content-Type: text/xml; charset=ISO-8859-1 2008-11-28 14:15:41.108186 soap_transport_http: set header SOAPAction: "os_ReservaMaterialCrear" 2008-11-28 14:15:41.108516 soap_transport_http: setCredentials username=xi_bsanet authtype=basic digestRequest= array(0) { } 2008-11-28 14:15:41.108760 soap_transport_http: certRequest= array(0) { } 2008-11-28 14:15:41.109012 soap_transport_http: set header Authorization: Basic eGlfYnNhbmV0OnhpX2JzYW5ldA== 2008-11-28 14:15:41.109666 soap_transport_http: entered send() with data of length: 905 2008-11-28 14:15:41.109929 soap_transport_http: connect connection_timeout 0, response_timeout 30, scheme http, host benelus, port 50100 2008-11-28 14:15:41.110210 soap_transport_http: calling fsockopen with host benelus connection_timeout 0 2008-11-28 14:15:41.114084 soap_transport_http: set response timeout to 30 2008-11-28 14:15:41.114436 soap_transport_http: socket connected 2008-11-28 14:15:41.114706 soap_transport_http: set header Content-Length: 905 2008-11-28 14:15:41.114948 soap_transport_http: HTTP request: POST /XISOAPAdapter/MessageServlet?channel=:BSANET_DEV:bsanet_CrearReserva_SOAP_Client&version=3.0 HTTP/1.0 2008-11-28 14:15:41.115186 soap_transport_http: HTTP header: Host: benelus:50100 2008-11-28 14:15:41.115427 soap_transport_http: HTTP header: User-Agent: NuSOAP/0.7.3 (1.114) 2008-11-28 14:15:41.115659 soap_transport_http: HTTP header: Content-Type: text/xml; charset=ISO-8859-1 2008-11-28 14:15:41.115891 soap_transport_http: HTTP header: SOAPAction: "os_ReservaMaterialCrear" 2008-11-28 14:15:41.116297 soap_transport_http: HTTP header: Authorization: Basic eGlfYnNhbmV0OnhpX2JzYW5ldA== 2008-11-28 14:15:41.116994 soap_transport_http: HTTP header: Content-Length: 905 2008-11-28 14:15:41.117634 soap_transport_http: wrote data to socket, length = 1230 2008-11-28 14:15:54.436566 soap_transport_http: read line of 36 bytes: HTTP/1.1 500 Internal Server Error 2008-11-28 14:15:54.437070 soap_transport_http: read line of 19 bytes: Connection: close 2008-11-28 14:15:54.437478 soap_transport_http: read line of 97 bytes: Set-Cookie: JSESSIONID=(benelus_XID_01)ID1232314650DB11656244804724496146End; Version=1; Path=/ 2008-11-28 14:15:54.437893 soap_transport_http: read line of 65 bytes: Set-Cookie: saplb_*=(benelus_XID_01)18594450; Version=1; Path=/ 2008-11-28 14:15:54.438309 soap_transport_http: read line of 30 bytes: Server: SAP J2EE Engine/7.00 2008-11-28 14:15:54.438704 soap_transport_http: read line of 39 bytes: Content-Type: text/xml; charset=utf-8 2008-11-28 14:15:54.439092 soap_transport_http: read line of 37 bytes: Date: Fri, 28 Nov 2008 13:13:27 GMT 2008-11-28 14:15:54.439490 soap_transport_http: read line of 2 bytes: 2008-11-28 14:15:54.440002 soap_transport_http: found end of headers after length 325 2008-11-28 14:15:54.440743 soap_transport_http: found cookie: JSESSIONID = (benelus_XID_01)ID1232314650DB11656244804724496146End 2008-11-28 14:15:54.441371 soap_transport_http: found cookie: saplb_* = (benelus_XID_01)18594450 2008-11-28 14:15:54.442016 soap_transport_http: want to read content to EOF 2008-11-28 14:15:54.515850 soap_transport_http: read buffer of 1258 bytes 2008-11-28 14:15:54.516177 soap_transport_http: read to EOF 2008-11-28 14:15:54.516412 soap_transport_http: read body of length 1258 2008-11-28 14:15:54.516648 soap_transport_http: received a total of 1583 bytes of data from server 2008-11-28 14:15:54.516996 soap_transport_http: closed socket 2008-11-28 14:15:54.517259 soap_transport_http: No Content-Encoding header 2008-11-28 14:15:54.517502 soap_transport_http: end of send() 2008-11-28 14:15:54.517760 nusoap_client: Setting new cookie(s) 2008-11-28 14:15:54.518012 nusoap_client: got response, length=1258 type=text/xml; charset=utf-8 2008-11-28 14:15:54.518369 nusoap_client: Entering parseResponse() for data of length 1258 headers: array(5) { ["connection"]=> string(5) "close" ["set-cookie"]=> string(51) "saplb_*=(benelus_XID_01)18594450; Version=1; Path=/" ["server"]=> string(20) "SAP J2EE Engine/7.00" ["content-type"]=> string(23) "text/xml; charset=utf-8" ["date"]=> string(29) "Fri, 28 Nov 2008 13:13:27 GMT" } 2008-11-28 14:15:54.518652 nusoap_client: Got response encoding: utf-8 2008-11-28 14:15:54.518926 nusoap_client: Use encoding: UTF-8 when creating nusoap_parser 2008-11-28 14:15:54.519454 nusoap_parser: No encoding specified in XML declaration 2008-11-28 14:15:54.519874 nusoap_parser: Entering nusoap_parser(), length=1258, encoding=UTF-8 2008-11-28 14:15:54.520640 nusoap_parser: found root struct Fault, pos 2 2008-11-28 14:15:54.521967 nusoap_parser: in buildVal() for SystemError(pos 6) of type 2008-11-28 14:15:54.522387 nusoap_parser: in buildVal, there are children 2008-11-28 14:15:54.522811 nusoap_parser: in buildVal, adding Java Vector or generic compound type SystemError 2008-11-28 14:15:54.523256 nusoap_parser: in buildVal, return: array(3) { ["context"]=> &string(9) "XIAdapter" ["code"]=> &string(22) "ADAPTER.JAVA_EXCEPTION" ["text"]=> &string(720) " com.sap.aii.af.ra.ms.api.DeliveryException: Application:EXCEPTION_DURING_EXECUTE: at com.sap.aii.adapter.xi.ms.XIEventHandler.onTransmit(XIEventHandler.java:455) at com.sap.aii.af.ra.ms.impl.core.queue.consumer.CallConsumer.onMessage(CallConsumer.java:134) at com.sap.aii.af.ra.ms.impl.core.queue.Queue.run(Queue.java:917) at com.sap.aii.af.ra.ms.runtime.MSWorkWrapper.run(MSWorkWrapper.java:56) at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37) at java.security.AccessController.doPrivileged(AccessController.java:207) at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:102) at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:172) " } 2008-11-28 14:15:54.523771 nusoap_parser: in buildVal() for detail(pos 5) of type 2008-11-28 14:15:54.524181 nusoap_parser: in buildVal, there are children 2008-11-28 14:15:54.524601 nusoap_parser: in buildVal, adding Java Vector or generic compound type detail 2008-11-28 14:15:54.525022 nusoap_parser: in buildVal, return: array(1) { ["SystemError"]=> &array(3) { ["context"]=> &string(9) "XIAdapter" ["code"]=> &string(22) "ADAPTER.JAVA_EXCEPTION" ["text"]=> &string(720) " com.sap.aii.af.ra.ms.api.DeliveryException: Application:EXCEPTION_DURING_EXECUTE: at com.sap.aii.adapter.xi.ms.XIEventHandler.onTransmit(XIEventHandler.java:455) at com.sap.aii.af.ra.ms.impl.core.queue.consumer.CallConsumer.onMessage(CallConsumer.java:134) at com.sap.aii.af.ra.ms.impl.core.queue.Queue.run(Queue.java:917) at com.sap.aii.af.ra.ms.runtime.MSWorkWrapper.run(MSWorkWrapper.java:56) at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37) at java.security.AccessController.doPrivileged(AccessController.java:207) at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:102) at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:172) " } } 2008-11-28 14:15:54.525526 nusoap_parser: in buildVal() for Fault(pos 2) of type struct 2008-11-28 14:15:54.525944 nusoap_parser: in buildVal, there are children 2008-11-28 14:15:54.526359 nusoap_parser: in buildVal, adding Java Vector or generic compound type Fault 2008-11-28 14:15:54.526798 nusoap_parser: in buildVal, return: array(3) { ["faultcode"]=> &string(11) "SOAP:Server" ["faultstring"]=> &string(12) "Server Error" ["detail"]=> &array(1) { ["SystemError"]=> &array(3) { ["context"]=> &string(9) "XIAdapter" ["code"]=> &string(22) "ADAPTER.JAVA_EXCEPTION" ["text"]=> &string(720) " com.sap.aii.af.ra.ms.api.DeliveryException: Application:EXCEPTION_DURING_EXECUTE: at com.sap.aii.adapter.xi.ms.XIEventHandler.onTransmit(XIEventHandler.java:455) at com.sap.aii.af.ra.ms.impl.core.queue.consumer.CallConsumer.onMessage(CallConsumer.java:134) at com.sap.aii.af.ra.ms.impl.core.queue.Queue.run(Queue.java:917) at com.sap.aii.af.ra.ms.runtime.MSWorkWrapper.run(MSWorkWrapper.java:56) at com.sap.engine.core.thread.impl3.ActionObject.run(ActionObject.java:37) at java.security.AccessController.doPrivileged(AccessController.java:207) at com.sap.engine.core.thread.impl3.SingleThread.execute(SingleThread.java:102) at com.sap.engine.core.thread.impl3.SingleThread.run(SingleThread.java:172) " } } } 2008-11-28 14:15:54.527370 nusoap_parser: parsed successfully, found root struct: 2 of name Fault [/code] Any ideas? |
||||||||||||||
|
|
Ok, it's solved At the end i was able to send the xml string just with this:
|
||||||||||||||
|
Problem consuming SAP-XI webservice |
|
||
Content © NuSphere Corp., PHP IDE team
Powered by phpBB © phpBB Group, Design by phpBBStyles.com | Styles Database.
Powered by
Powered by phpBB © phpBB Group, Design by phpBBStyles.com | Styles Database.
Powered by