Exception handling in synchronous client proxy

Hi, I have a synchronous outbound proxy-web service scenario. If our Post request (unknown data in the receiver) fails, the receiver system returns a 404 error that results in application error in PI. Now, I want know how to handle CX_AI_APPLICATION_FAULT using the standard fault message type (ExchangeFaultData). I couldn't find any reference for synchronous client proxies using this. I hope you can help me out. Thank you.

Hi Mark,
You have a link here How to handle CX_AI_SYSTEM_FAULT in RFC - Code Gallery - SCN Wiki or here https://help.sap.com/saphelp_nw04/helpdata/en/75/a55c3cff8ca92be10000000a114084/content.htm
I dont know what is your exact problem, you can retrieve certain information in the ABAP code but i usually set a generic message like "Connection unsuccessful" because if you debbug the object the information is so technical to be showed to a client.
Hope this helps.
Regards.

Similar Messages

  • Synchronous Client Proxy to JDBC !!

    Hi,
    My scenario is like this:
    I am working on a synchronous scneario where SAP is sending
    using synchronous client proxy to a database and after uploading
    of data on JDBC side, the response(Success/Failure) flag has to be
    sent back to SAP.
    Please let me know how this scneario can be designed and if BPM is required here.
    Thanks...

    Hi,
    Go thru  this
    http://help.sap.com/saphelp_nw70/helpdata/en/45/20d251c20a0732e10000000a155369/content.htm
    https://forums.sdn.sap.com/click.jspa?searchID=8242639&messageID=4482651
    /people/bhavesh.kantilal/blog/2006/07/03/jdbc-receiver-adapter--synchronous-select-150-step-by-step
    /people/swaroopa.vishwanath/blog/2006/12/28/send-rfc-to-sap-xi-150-asynchronous
    /people/bhavesh.kantilal/blog/2006/07/03/jdbc-receiver-adapter--synchronous-select-150-step-by-step
    https://weblogs.sdn.sap.com/pub/wlg/1403 [original link is broken] [original link is broken] [original link is broken]
    JDBC Synchronous call  using BPM
    Regards
    Agasthuri Doss

  • RFC calls & Synchronous Client Proxy

    If I want to execute a Synchronous Client Proxy, sending request to XI and waiting for response from XI, do I HAVE TO define and import a RFC structure ?
    My doubt is whether implementing RFC is a must in this case, or we can just define a equivalent structure (to the RFC structure: request & response), define all the mapping and create the proxy accordingly and it will work?
    Your help is appreciated.

    Hi!
    No, you don't need to do that. Simply define your interface and generate proxies.
    Peter

  • Error in Synchronous client proxy

    Hi Gurus,
    I have created a scenario in which I am using client proxy at source side (ECC ) and soap at target side.
    Its a synchronous scenario for which I have written an abap report.This interface sends a company name and uses a webservice to fetch the stock value of that company.
    I am a beginner in abap, so I am unable to to know the reason why is it showing the following error when I am executing the code.
    Method "EXECUTE_SYNCHRONOUS" is unknown or PROTECTED or PRIVATE.
    This error is coming at line :
    CALL METHOD Proxy->execute_synchronous
    Following is the code :
    REPORT  ZSYNC_PROXY_STOCKQUOTE NO STANDARD PAGE HEADING.
    DATA Proxy TYPE REF TO ZCO_SI_SOURCE.
    CREATE OBJECT Proxy.
    DATA: t_company_name TYPE zsource_request_mt,
           t_stock_value TYPE zsource_response_mt.
    SELECTION-SCREEN: BEGIN OF BLOCK B1.
    PARAMETER: p_id TYPE String.
    SELECTION-SCREEN: END OF BLOCK B1.
      START-of-selection.
      TRY.
        t_company_name-Source_Request_MT-Company_name = p_id.
        CALL METHOD Proxy->execute_synchronous
        Exporting
          output = t_company_name
       IMPORTING
         input = t_stock_value.
       WRITE: t_stock_value-Source_Response_MT-stock_value.
       CATCH cx_ai_system_fault.
         DATA fault TYPE REF TO cx_ai_system_fault.
         CREATE OBJECT FAULT.
        WRITE:/ fault->errortext.
        ENDTRY.
        END-OF-SELECTION.

    Hi,
    You have wrongly assigned the method. It should not be pointing to Execute method.
    it should be something like below
    TRY.
               CREATE OBJECT proxy.
               CATCH cx_ai_system_fault.
      ENDTRY.
    TRY.
        CALL METHOD Proxy->  " GIVE THE OUTBOUND SERVICE INTERFACE NAME HERE"
        Exporting
          output = t_company_name
       IMPORTING
         input = t_stock_value.

  • Fault message handling in abap client proxy

    Hi experts,
    i have scenario like this SAPECC---XI---WEBservice
    i was decided to using the ABAP CLIENT proxy in sender side and soap adapter communication in receiver side
    i will be get the wsdl file form client
    problem is i am in bit of confusion like  am i need to create fault message for this asychronous scenario?
      how can i create the fault message for this scenario(that WSDL) and how the abaperwill  handle those error
    thanks in advance

    Hi.
    You can use fault message but it won´t return a error to your ABAP Proxy because your interface is ASSYNC. The fault message generated will stop in Adapter Engine.
    If you need a return of the error, you have to change your interface to Sync mode.
    To get more information, follow the link below:
    Fault Message Type
    http://help.sap.com/saphelp_nwpi711/helpdata/en/dd/b7623c6369f454e10000000a114084/frameset.htm
    Best Regards.
    Bruno

  • Exceptions while creating ABAP client Proxy

    Hi Experts,
    I tried to create a client proxy on the CRM system for a web service URL (where the WSDL exists), in the transaction SE80.
    When I tried creating this, i got exception as follows.
    Exception occured in communication framework:error in HTTP framework:404 conn failed http://inld50054696a:8080/clearspace/rpc/rest?forumservice?wsdl
    Please let me know, how to tackle this problem.
    What are all the settings that needs to be done in this regard.
    Regards
    Lakshman

    Have you verified that your SAP system is set up to be able to send messages out over http?  Our firewalls caused the same problem- by configuring proxy settings in transaction SICF we worked around the error.
    Hope that helps!
    Abby

  • Exception when creating ABAP client proxy using WSDL

    Hi Experts,
    I tried to create a client proxy on the CRM system for a web service URL (where the WSDL exists), in the transaction SE80.
    When I tried creating this, i got exception as follows.
    Exception occured in communication framework:error in HTTP framework:404 conn failed http://inld50054696a:8080/clearspace/rpc/rest?forumservice?wsdl
    Please let me know, how to tackle this problem.
    What are all the settings that needs to be done in this regard.
    Regards
    Lakshman

    Hi Vasanth,
    There are many threads and blogs on this topic.
    Choose the search Forum on the Forum page and select "All categories" in the Category field and enter your topic "ABAP client proxy from WSDL" in the search field.
    Rgds,
    Sam Raju

  • Exception handling in synchronous proxy - web service scenario

    Hi Gurus,
    I have a synchronous scenario in which SAP is sending a request via XI using SOAP and receiving a response back. As part of this scenario, I am consuming standard web service APIs provided by the third party.
    Since, every request has to contain the connecting user id and password provided by the third party, I am sending/receiving messages without SOAP envelop (achieved by clicking 'Do not use SOAP envelope' checkbox in SOAP Receiver Communication Channel).
    For this scenario, we are including the user id and password in the request message using XSLT mapping and the request number using simple message mapping.
    The fault message of the web service is being mapped to the fault message created in XI under Fault Message Types.
    The interface mapping page has got 3 tabs, one each for Request message mapping, Response message mapping and Fault message mapping.
    When I trying to test a failure scenario by giving an incorrect request number(since this is the only input parameter in gthe request message apart from user id and password), it is throwing up "MAPPING">EXCEPTION_DURING_EXECUTE error.
    Actually, for such requests, I am getting a proper fault response back from the third party which I can see in XI (in moni) as response to my request but when I am looking at the message in moni in SAP, I am only seeing "MAPPING">EXCEPTION_DURING_EXECUTE. Even I can see the exception in the trace section of my response in moni in XI.
    My feeling is that the fault message mapping is not getting executed at all.
    I also thought to do a 2:1 multimapping in which, the target side will contain the response message type created in XI but the source will contain two messages, i.e. Normal response message structure provided by third party and Fault message structure provided by third party but I am not sure whether this is possible without using BPM.
    Please suggest the best way to resolve this issue.

    The Fault message raised from 3rd party service, is structured as follow ??
    HTTP/1.1 500 Internal Server Error
    Content-Type: text/xml; charset="utf-8"
    Content-Length: nnnn
    <SOAP-ENV:Envelope
      xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
       <SOAP-ENV:Body>
           <SOAP-ENV:Fault>
               <faultcode>SOAP-ENV:Server</faultcode>
               <faultstring>Server Error</faultstring>
               <detail>
                   <e:myfaultdetails xmlns:e="Some-URI">
                     <message>My application didn't work</message>
                     <errorcode>1001</errorcode>
                   </e:myfaultdetails>
               </detail>
           </SOAP-ENV:Fault>
       </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>
    Take a look here:
    /people/jin.shin/blog/2007/05/21/handling-web-service-soap-fault-responses-in-sap-netweaver-xi
    and to this standard document:
    http://help.sap.com/saphelp_nwpi711/helpdata/en/48/5946db5f693912e10000000a42189b/content.htm

  • Error/Exception handling in PI (Inbound Proxy)

    Dear All,
    I need some help in PI Error handling.
    If PI sends data to an ABAP inbound proxy and an error occurs in PI because of type mismatch (e.g. Unable to convert date).
    This error is persistent in the PI monitor, but how do I let the Sender know that an error has occured?
    regards,
    Piyush

    Hi,
    I understand that you have a doubt, if PI sends data to ABAP inbound proxy and an alert reaised due to type mismatch. Now, you would like to know how to acknowledge that sender to know about the alert?
    First of all, get the payload and test in the message mapping, you will get know where exactly you got the error or check in the trace in Moni. You need to identify the issue and let the user know why exactly it failed.

  • Exception handling in outbound ABAP proxy

    Hi All,
    i need to catch exception in outbound abap proxy in two cases:
    1. if RFC dest in R3 which is pinging to XI goes down.
    2. IF xi server is down.
    in both the cases i need to catch the exceptions.
    now i written the code in this way:
    DATA: v_exceptions TYPE REF TO cx_ai_system_fault.
    TRY.
    CALL METHOD zirco_o_msg_if_as_req_details=>execute_asynchronous
    EXPORTING
    output = s_reference.
    COMMIT WORK.
    CATCH cx_ai_system_fault INTO v_exceptions.
    WRITE: 'Exception CX_AI_SYSTEM_FAULT caught'.
    WRITE: / v_exceptions->errortext.
    WRITE: / v_exceptions->code.
    but this code is not working.
    can anybody tell me how can i acheive this?

    Hi All,
    I need to log the error when receiver syatem is down.
    Its like this:
    Outbound proxy >>>XI>>>File adapter..
    Now if xi goes down....means message is succussefully sent from ISD and get stuck in XI then i need to catch this exception in ISD.
    Is it possible?? if yes then how??
    Kunaal

  • Exception Handling in Webservice Client

    Hi..I have a webservice (JWS) running on Tomcat and Apache AXIS..which is installed on different sites/locations..I have a search portal (JSP) that will invoke that webservices and return an array of values in SOAP.
    My problem is how can my Jsp page as client of webservice..detect that the webservice is down, or the tomcat is not started? I also want to check periodically if the webservice on different site is available (online) or not..if not an email will be automatically send to the administrator..reminding him to start the service..
    how can i determined if a webservice is down from my jsp page?
    Thanks in advance for your help..

    does it returm a value error 404 page cannot blah bla blah?

  • Exception handling in client proxy

    Hi
    Can someone please help me with exception handling in ABAP client proxy.

    HI
      Welcome to SDN
    Check this link you wil get information regarding ABAP Proxy  http://help.sap.com/saphelp_nw04/helpdata/en/c9/74246d8ad2447799063d39013e9a11/content.htm

  • Error Handling in Inbound ABAP Proxy with EOIO

    Hi,
    The scenario
    I have a File to ABAP Proxy scenario and since the requirement is that the messages have to be processed in a single queue in the SAP system (i.e. EOIO), the sender file channel was configured to be EOIO. This ensures that all messages that enters the SAP system are put in a single queue and then processed one after the other.
    The Issue
    Now if one of the messages that enter SAP system fails during the processing in the ABAP program, the queue gets stuck and all messages after that go into a scheduled state. And one has to manually clear the errored message in order to continue processing the other waiting messages.
    The Question
    I know this is a default behavior in an EOIO scenario, however is there any way in which if a message fails in the ABAP program then one can automatically push it out of the queue and keep processing the other messages after it ?
    Thanks
    Bharath

    As a general rule I only use EOIO when there is a possibility of dependancy between messages (message 1 must be first and finsihed before message 2 starts). Assuming your just moving the errored message asside, I would assume that EOIO should be just EO.
    Alternatively, change the ABAP proxy to handle the error and return a clean status. Exception handling (try/catch) should be used were ever dangerous code is being used.
    If alerting in the proxy end point is to much trouble - change your proxy to a sync scenario return the error to PI and fire alerts from there <- I think this should be avoided but it will work.
    The main point is the exception handling so that the proxy fails "gracefully".

  • Scenario SOAP - PI - PROXY - Exception handling

    Hi all,
    I have the following scenario:
    Scenario SOAP(.NET)  <-> PI <-> PROXY
    When I raise an exception at the proxy side, PI will be informed with an exception text that an exception has occured.
    In the .NET receiver I only get an application exception (but not the real exception) - no exception text
    How can I get the exception text at .NET side?
    There is a datatype of type "XXXXException".
    But I can't use this class in the catch block because it is not inherited from class exception.
    regards

    Hi,
    thanks for your answer.
    But how to handle the exception in my C# client:
    I have created the .NET classes out of the WSDL
    There is a class ZQM_SVC_QMEL_GETException generated, but I don't know how to use it.
    try
                res.ES_SVC_QMEL = client.MI_OSRBG_QM_MASTERDATA_AUDIT_QMEL_GET_SYNC_OUT("123");
            catch (ZQM_SVC_QMEL_GETException  ex1)
    This coding is not working because the class ZQM_SVC_QMEL_GETException is not inherited from the class exception.
    This class has an attribute Nodes and several methods getSchema, ReadXML, WriteXML.
    But I don't know how to use it.
    Any idea?
    regards

  • System exception after a succesful synchronous ABAP Proxy call

    Guys,
    I have the following scenario:
    1) From an R/3 box I initiate a synchronous ABAP proxy call
    2) On XI everything works fine, the http request is sent out (using the http adapter), the response comes back succesfully and it is transfered back to the R/3 box - no error whatsoever
    3) On the R/3 box however the EXECUTE_SYNCHRONOUS method throws a system exception BUT the returning (input) parameter holds the response message!
    So in the end if I catch this exception (CX_AI_SYSTEM_FAULT) then I could be happy and just ignore the exception, but I don't feel comfortable leaving it this way. Why is the exception and how can I eliminate it?
    Any help would be greatly appreciated.
    Thanks a lot,
    Viktor

    Joel/Jörg,
    Thank you for your response, indeed I ended up debugging it and found my error deep down:
    Error code: ABAP_PROXY.PARSE_APPLICATION_DATA
    Error text: Error handling Response Message; XSLT error: CX_XSLT_DESERIALIZATION_ERROR: XSLT program and source line: /1SAI/XS00000000000000000088: 0000000122; Tree Position: abap.values.1.1.1.6.1.5 ABAP Classname: CX_SY_CONVERSION_DATA_LOSS Data String: WINDSOR CT 06095-1712
    The data field defined in SAP was too short for the field.
    Thanks a lot,
    Viktor

Maybe you are looking for

  • Problem with nokia n95

    i bougt in February 2010 a Nokia n 95 (code IMEI) that in October went out of work. I brought the telephone to the Nokia Assistance Center in Modena, Italy, where I live, but, after two weeks the answer was that the phone was rusty inside and therefo

  • Apple's Apache 2.0.54, PHP 5.0.4 and MySQL 5.0.18

    Hello Using OSX Server 10.4.4. I'm considering using Apple's /opt Apache 2.0.54 with the builds of PHP 5.0.4 and MySQL 5.0.18. Has anyone any experience with this combination and any warnings / advice? MySQL 5.0.18 is an installer straight from MySQL

  • Script output types

    Hai friends i am a new of the script, i dont know the script output type of sales order, purchase order, and some script output types. thanks & Regards kumar

  • [svn] 2178: when compiling 3.0.x use 1.4 compatibility.

    Revision: 2178 Author: [email protected] Date: 2008-06-23 08:03:55 -0700 (Mon, 23 Jun 2008) Log Message: when compiling 3.0.x use 1.4 compatibility. -added a variable so this can be set globally in the build.xml in the root or individually in the mod

  • Error while installing NetBeans 4.1 Installation

    My system running win XP (SP2) and java SDK 1.4.1. I found error "a suitable jvm could not be found. please run the program again using the option -is:javahome <java home dir>" while installating NetBeans 4.1. I tried to use option to install from co