Call ABAP Proxy

Hi,
I'm trying to call a proxy interface (outbound) by calling the class behind the proxy.
everything works... the XML gets created from the proxy and is shown in SXMB_MONI, but unfortunately the XML gets not send to the corresponding Inbound Interface (which is configured in XI)
if I use SPROXY for testing the Outbound proxy the XML will be sent to the Inbound interface, but not with my class-call
so what needs to be done before or after calling the class to ensure that the XML gets sent to Inbound Interface?
I debugged the test in SPROXY and came to class CL_AI_RUNTIME_TEST maybe the following coding needs to be added before calling the proxy class:
        CREATE OBJECT l_proxy TYPE (r3object_sender-class).
        TRY.
            l_routing_prot ?= l_proxy->get_protocol( if_wsprotocol=>routing ).
            DATA:
              l_routing_prot_local TYPE REF TO cl_wsprotocol_routing.
            l_routing_prot_local ?= l_routing_prot.
            l_routing_prot_local->set_sender( selections->sender-address ).
but I'm not sure about that... (cannot try this atm)

solved... COMMIT WORK was needed :-|

Similar Messages

  • Abap report for calling abap proxy?

    why do we need  to write abap report for calling abap proxy? i mean what's the use of abap report and what are the things inside the report ...please give me details about abap report.

    Hi,
    In SPROXY for your outbound interface you generate the proxy class.
    The ABAP report is used to fill the data from the ABAP tables and then trigger the call to XI using this class.
    Look into the code in this blog and check what is done,. The data is filled in the report and then the call is made to XI using an object of the class created in SPROXY using the EXECUTE_ASYNCHRONOUS method.
    /people/ravikumar.allampallam/blog/2005/03/14/abap-proxies-in-xiclient-proxy
    Regards
    Bhavesh

  • How to call abap proxy at run time?

    hello frnds,
    i m working on a scenario in which whenever Invoice is saved in SAP R/3 at that time same data should go to Oracle DB. i m using ABAP proxy on SAP R/3 side and JDBC receicver adapter on oracle side of XI.
    so to post data i need to call ABAP Proxy whenever invoice is saved.. i have tried to find out save event for invoice but not able to get... can anybody tell me the solution that how i can call proxy at run time?
    thanx in advance.
    Regards,
    Hetal.....

    Hi Audumbar,
    Check these ...
    /people/vijaya.kumari2/blog/2006/01/26/how-do-you-activate-abap-proxies
    /people/siva.maranani/blog/2005/04/03/abap-server-proxies
    /people/vanita.thareja2/blog/2006/05/23/bpm-sending-message-asynchronously-and-getting-the-response-from-synchronous-system-using-abap-proxies
    /people/ravikumar.allampallam/blog/2005/03/14/abap-proxies-in-xiclient-proxy
    cheers,
    Prashanth
    P.S Please mark helpful answers

  • Call ABAP-Proxy with SOAP adapter?

    Hi all,
    for a PI7.1-scenario I would like to use the Lookup-API in mapping. As I know I can use either RFC or SOAP channels, however I would rather call an ABAP-Proxy in my backend system instead.
    So my question is: Is it technically possible to use the SOAP-adapter to call an ABAP-Proxy?
    Your help would be appreciated, best regards
    David

    Hi Stefan,
    Interesting answer here and one that has got me curious. Hope you can help.
    1. When you say it is going to be possible to call a ABAP proxy using a  UDF in the mapping of XI ( Lookup ), would it be using the WS Adapter of PI 7.1?
    2. If 1 is yes, is there a new API code to do this, or is it the same lookup code as used previously in XI 3.0 and PI 7.0 Days?
    3. If 1 is no, can you explain maybe a little more on how this would be possible using the standard SOAP adapter of XI?
    Thanks a bunch.
    Regards
    Bhavesh

  • Calling abap proxy synchronous ...

    Hi everyone.
    I have this scenario.
    abap proxy (request) -
    > XI (BPM) -
    > abap proxy (response).
    I'm able to send async the data using the proxy and i would like to send the response to other proxy.
    The best scenario for me would be if the proxy in sync, the BPM do some checks and finally, sender proxy returns the values.
    any idea of how to do this two scenarios?
    Regards,
    Inigo.

    Hi,
    >>>abap proxy (request) -
    > XI (BPM) -
    > abap proxy (response).
    are you sure that processing inside the BPM will take less then 30 sec?
    if not why do you want a syn call ? do you use this sync proxy call
    from an online report in r3 ?
    if you don't need a sync report do it in an async way:
    proxy - BPM - proxy (which writes the results to a table)
    and then from your report you can read from that table...
    one of the possibilities
    Regards,
    michal

  • Exception when calling ABAP Proxy modelled in SAP PI: CL_SOAP_RUNTIME_ROOT

    Hi,
    We have a scenario where we:
    1. Modell an interface in SAP PI
       This interface contains a complex type from a different namespace
    2. Use it to create an ABAP proxy in backend system
    3. Configure it with SOAManager
    4. Call the ABAP proxy ws directly from a third-party system (biztalk)
    We're currently testing calling the ABAP proxy from soapUI, but get a strange exception thrown by the SOAP framework in ABAP backend.
    The test in soapUI is setup by importing the WSDL acquired from SOAMANAGER.
    The error message we in the SOAP response is:
    CX_SY_REF_IS_INITIAL:Exception CX_SOAP_ROOT occurred
    (program: CL_SOAP_RUNTIME_ROOT==========CP, include: CL_SOAP_RUNTIME_ROOT==========CM004, line: 130)..
    An exception with the type CX_SY_REF_IS_INITIAL occurred, but was neither handled locally,
    nor declared in a RAISING clause.Dereferencing of the NULL reference
    It is a very low level error from the CL_SOAP_RUNTIME_ROOT program and not a descriptive error message at all.
    We've checked the user and the authorizations it has, we've redone the SOAManager config but the problem persists.
    We find no dumps in the ABAP proxy since the request never reaches it.
    For a limited time I'll make WSDL and SOAP response available
    WSDL (some values anonymized) available at http://dl.dropbox.com/u/4379928/SOAP/project.wsdl
    Complete SOAP response is available at http://dl.dropbox.com/u/4379928/SOAP/soap_data.xml
    Any ideas on where to look?

    Hi,
    We've now managed to implement a workaround.
    The workaround was to create the endpoint in PI as well.
    So that the traffic goes from third-party solution->PI-> WS-enabled ABAP Proxy
    When we did this initially, we got some errors related to the asynch method of this call, but this was resolved by changing the channel from "best effort" to "Guaranteed delivery". 
    Still we don't know what the root cause of the initial problem was, but we assume it is related to the asynch nature of the service (though we have other asynch proxies that work without problems).
    Regards
    Dagfinn

  • Abap proxy call : synchronous / background ?

    Hi,
    I use currently abap proxy call to send data from ECC to XI, and it works fine ! But... I would like to know two points :
    1. Is it possible to execute SYNCHRONOUSLY this call abap proxy and not only in asynchronous...
    2. Is it possible to execute in BACKGROUND this call abap proxy, because it seems it use a dialog process, even if the call is inside an abap program executed in background
    I will appreciate your feedbacks on these both points ?
    Regards.
    Mickael

    Hi,
    Yes, we can do Sysnchronous call in Proxy.
    and we can do the Background job schedule also in Proxy .
    Reffer this help file
    http://help.sap.com/saphelp_nw04/helpdata/en/86/58cd3b11571962e10000000a11402f/content.htm
    Reffer this BLOG also
    /people/sravya.talanki2/blog/2006/07/28/smarter-approach-for-coding-abap-proxies
    Regards
    Seshagiri
    Edited by: N V Seshagiri on Feb 12, 2008 11:19 AM

  • Problem receiving acknowledgement: abap proxy == file adapter

    Hi experts,
    I am developing an asynchrone interface using PI 7.0. The scenario is: SAP ==> FILE.
    In SAP I have created an abap proxy in wich I requested an acknowledgement when calling from the abap code. In PI I have created an Integration Process with a receive step, and a send step. In de send step I am asking for a transport acknowledgement.
    When I test the interface and I look in the SXMB_MONI in PI, I see the acknowledgement given back to the IP, but in the SAP backend system I don't receive anything in the abap proxy which had send the original message. In de SXMB_MONI from SAP I see a "?" Still awaiting  acknowledgement.
    Can anyone help me with this scenario? I really need an acknowledgement from the file adapter in the calling abap proxy.
    Regards, Jeroen

    You need to crate a REceiver Agreement for this sender...
    The Integration Server sends an acknowledgment message back to the sender (CENTRAL_BACK). It uses the name of the sender system for logical and technical backward routing.
    If the sender is addressed using an ABAP proxy, you must define a corresponding receiver agreement for this sender.
    http://help.sap.com/saphelp_nw04/helpdata/en/29/345d3b7c32a527e10000000a114084/content.htm
    -SM

  • ABAP Proxy to HTTP Synchronous

    Hi All,
    My scenario is ABAP Proxy to HTTP POST synchronous, while I am trying to execute the scenario I get the following error in SXMB_MONI:
      <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Call Adapter
      -->
    - <SAP:Error SOAP:mustUnderstand="1" xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
      <SAP:Category>XIAdapter</SAP:Category>
      <SAP:Code area="PLAINHTTP_ADAPTER">ATTRIBUTE_SERVER</SAP:Code>
      <SAP:P1>404</SAP:P1>
      <SAP:P2>Not Found</SAP:P2>
      <SAP:P3><Exception><Status>The resource you requested does not exist</Status><Reason>Event does not exist</Reason><Code>404</Code></Exception></SAP:P3>
      <SAP:P4 />
      <SAP:AdditionalText />
      <SAP:Stack>HTTP server code 404 reason Not Found explanation <Exception><Status>The event resource you requested does not exist</Status><Reason>Event does not exist</Reason><Code>404</Code></Exception></SAP:Stack>
      <SAP:Retry>M</SAP:Retry>
      </SAP:Error>
    What I understand is the target HTTP server sends a error response because my request xml data is not valid
    How do I structure my response message type and how do I map this response to the calling ABAP Proxy. The target HTTP server says if the data is fine they will send a success message in the http header, how do i map this response from http header back to calling ABAP Proxy.
    Thx in advance
    Ravijeet

    Hi Abhishek,
    The target http server says that if my xml request data is valid then they will send a response back in the http header in a field call route.
    And if the xml request data is not valid then they will throw an exception, which I am getting from the target http server as below in SXMB_MONI :
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Call Adapter   -->
    - <SAP:Error SOAP:mustUnderstand="1" xmlns:SAP="http://sap.com/xi/XI/Message/30" xmlns:SOAP="http://schemas.xmlsoap.org/soap/envelope/">
      <SAP:Category>XIAdapter</SAP:Category>
      <SAP:Code area="PLAINHTTP_ADAPTER">ATTRIBUTE_SERVER</SAP:Code>
      <SAP:P1>400</SAP:P1>
      <SAP:P2>Bad Request</SAP:P2>
      <SAP:P3><Exception><Status>Bad Request</Status><Reason>ActivityId and ActivityStep combination already exists</Reason><Code>400</Code></Exception></SAP:P3>
      <SAP:P4 />
      <SAP:AdditionalText />
      <SAP:Stack>HTTP server code 400 reason Bad Request explanation <Exception><Status>Bad Request</Status><Reason>ActivityId and ActivityStep combination already exists</Reason><Code>400</Code></Exception></SAP:Stack>
      <SAP:Retry>N</SAP:Retry>
      </SAP:Error>
    What I want to know is do I need to create a response message type as below:
    <?xml version="1.0" encoding="UTF-8"?>
    <Exception>
       <Status/>
       <Reason/>
       <Code/>
    </Exception>
    Thx in advance
    Ravijeet

  • ABAP Proxy generation descrepencies with filed and method...

    Hello,
    I have two question regarding ABAP Proxies.
    The first one when i regenerate proxy for a interface, It is not generating the same filed as before and my ABAP program fails.
    I have Internal_organization_Descri -- Now, It is not giving same field rather It is giving Internal_organization_Descr
    It is missing 'i'
    One more problem is It is chaging method also
    Previously it was showing "Sales_order_Sync"
    Now, It is showing method as EXECUTE_SYNCHRONOUS
    Why It is these proxies behave differently, is there Service Pack dependency.. What is the best way to avoid these descripencies...Pls help
    Srinivas

    Hi,
    Please find the explantion about your doubts on ABAP Proxy.
    1. The field names might be changed based on the changes in XI in Data type for this field.
    Whenver you will be regenerating the ABAP Proxy, it considers the Message type and internally the Data types that have created in XI. So any changes in these objects may lead to change.
    Verify your field names in XI
    2. The Method to be used to call ABAP proxy is EXECUTE_SYNCHRON for Synchronous communciation and EXECUTE_ASYNCHRONOUS for async communication. These methods are used in ABAP source code. So please let me know where you had find this method "Sales_order_Sync"
    The EXECUTE_SYNCHRON is the proper method.
    Let me know if you need any more info.
    Refer
    ABAP Proxy outbound program - purchase order send
    https://www.sdn.sap.com/irj/sdn/wiki?path=/display/profile/abap%2bproxy%2boutbound%2bprogram%2b-%2bpurchase%2border%2bsend
    ABAP Proxy inbound program - sales order creation - Community Profiles - Wiki
    https://www.sdn.sap.com/irj/sdn/wiki?path=/display/profile/abap%2bproxy%2binbound%2bprogram%2b-%2bsales%2border%2bcreation
    Thanks
    Swarup

  • Web Service u0096 ABAP proxy  synchronous interface

    hi experts,
    can you suggest me how to do this scenario?
    <i><b>Web Service – ABAP proxy  synchronous interface.</b></i>

    hi,
    you can create a web service on XI
    which will call ABAP proxy (on ERP, SRM etc)
    in a synchronous way (you just need to generate the proxy class
    in TCODE SPROXY)
    then you can fill the method of your generated proxy class
    and you will have WS - ABAP proxy interface
    have a look at this to undrstand server proxy:
    /people/siva.maranani/blog/2005/04/03/abap-server-proxies
    Regards,
    michal
    <a href="/people/michal.krawczyk2/blog/2005/06/28/xipi-faq-frequently-asked-questions"><b>XI / PI FAQ - Frequently Asked Questions</b></a>

  • Code to use ABAP proxy

    hi all,
    can anybody please send me any sample code to call ABAP proxy.
    the ABAP proxy is already being created and i have all the class and methods names.
    i have to pick up some fields from a Z-table and have to send them as a message to XI.
    thanks in advance,
    shweta upadhyay.

    data:
    lo_clientproxy     type ref to <clinet proxy class name> ,
      lo_sys_exception   type ref to cx_ai_system_fault,
    Structures to set and get message content
       ls_request         type <type created in the clientn proxy generation>,
       ls_response        type <type created in the clientn proxy generation>,
    create object lo_clientproxy.
    try.
        call method lo_clientproxy-><method to call>
          exporting
            input  = ls_request
          importing
            output = ls_response.
      catch cx_ai_system_fault into lo_sys_exception.
      Error handling
    endtry.
    commit work.
    Regards
    Raja

  • How can I call a ABAP proxy class from BADI? PLease help

    hi Experts,
        I have a scenario where I have to call a ABAP proxy class from a BADI. How can I do this? Does anybody has sample code for the same?
    Please help.
    Thanks
    Gopal

    Hi,
       You can call a method of a class from BADI. Here are the steps.
       1) In the BADI implementation create a object for the proxy class.
       2) Call the Execute_Synchronous method.
        You can define a BADI by using SE18 and you can implement it by using SE19.
    Sample code...
    ================================================
      METHOD ZIF_EX_VBADI~CONVERTUPPER.
      DATA: OBJ TYPE REF TO ZTESTCLASS.
      DATA: IT_DATA  TYPE ZIN_MT,
                IT_RES   TYPE ZOUT_MT,
                SEXCEPTION TYPE REF TO CX_AI_SYSTEM_FAULT.
      TRY.
          CREATE OBJECT OBJ
             EXPORTING
                 LOGICAL_PORT_NAME = 'TESTPORT'.
      CATCH CX_AI_SYSTEM_FAULT INTO SEXCEPTION.
      ENDTRY.
    ENDMETHOD.
    ================================================
    Thanks,
    Vivek LR

  • User-exit/BADI during outbound ABAP proxy call

    Hello,
    I want to introduce certain check during outbound ABAP proxy calls to PI. This is a generic check, failure of which would stop the proxy call to proceed and raise an exception.
    I would like to place this at the generic place which is called for all the outbound ABAP proxy calls, rather than coding this in each and every outbound proxy class as the check is generic.
    Is there some user-exit/BADI where i can introduce this? Maybe within class CL_PROXY_OUTBOUND or somewhere else where i can introduce this check.
    Any help in this regard would be appreciated.
    Best Regards,
    Gajendra.

    Dear Gajendra ,
    i agree with sabrish, you must be having a z report on the application system that must be calling that outbound proxy...may be if the check is generic it may not be related to a proxy so you can code a FM and then call it before you call that proxy in the z report
    Giving points is another way to say thanks

  • Abap proxy to JDBC call

    The scenario is Sender is ABAP proxy and receiver side is JDBC adapter.
    While creating Purchase order(PO) in SAP, interface should be triggered and it should go and fetch the tax amount from a external Database(DB) and return the tax amount to SAP.
    PO can have mulitple line items so for each item it should get the tax amount from DB.
    I know we can change the occurence of Statement tag of JDBC structure to unbounded and accomplish multiple stored procedure calls.
    But how to handle multiple response from DB for each line item and send it as a single message to SAP.
    Is this possible without BPM ?

    For every purchase order there are mulitple line items and for each line item we need to extract tax amount.
    Question: Are these line items are in single db table or different? If it is one table, Why dont you use jdbc lookup during mapping time to fetch item amounts (Just using Select queries.. if the requirement is feasible) ?
    If there are multiple tables, receiving response from many tables might not be possible. If  response fails from first table then further query to the tables will not proceed. Jdbc treats entire query as one transaction.

Maybe you are looking for

  • Credit Segment Data Tab in Business partner master data

    Hi I have a situation where i am able to create Business partners from the Existing customers in ECC 6.0. For Credit management, when i am in UKM000 role i am unable to see Credit segment Data tab. Do i need to activate this any where? Your input is

  • Popups, focus, and J2SDK 1.4.2

    Hi, I have a program that draws a cartoon of a physical device in a JPanel and monitors mouse position, movement and left-clicks on the cartoon. When the user clicks a particular region of the cartoon, a popup containing a JTextField is displayed and

  • System Error occurs, with Japanese annotation.

    Dear Developers. I'm a user of "Adobe Reader for Android" in Japan. (This content is translated from Japanese.) When I open any PDF file with Adobe Reader for Android and put annotation comment in japanese,  "System error" occurs. Here is my steps. 1

  • What is "other" in your storage?

    when my iphone is connected to my itunes account, I can see how much storage I have available.  I see audio, apps,photos, and Other.  What is Other?  It is using up the most space.

  • Catch database failure exception

    Hello, i would like catch INSERT and UPDATE exception when it do some database error. If i use WHEN OTHERS i catch all exceptio ( i think database error too ), but i want to catch only database errors. How i can do? thanks!!!