<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Http request handler - Send response in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/http-request-handler-send-response/m-p/11112729#M1904189</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yeah, That is the way to cast using "?=" in ABAP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Glad to hear it worked.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 16 Jun 2015 09:05:38 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2015-06-16T09:05:38Z</dc:date>
    <item>
      <title>Http request handler - Send response</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/http-request-handler-send-response/m-p/11112725#M1904185</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Dear experts,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have an http communication - bidirectional - between SAP and a non-SAP system. In the direction from non-SAP to SAP, I defined a request handler using SE24 and SICF. Communication works fine.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;My problem is to send a response from SAP to the non-SAP system. I see that SERVER input parameter of implemented method HANDLE_REQUEST gives access to the response object by calling IF_HTTP_SERVER-&amp;gt;RESPONSE. To set the data of the response there is &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; IF_HTTP_RESPONSE-&amp;gt;SET_DATA by passing xstring as input parameter.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What I do not understand is how to actually send these data to the client - the non-SAP system that originally sent a request to SAP. I see no send mehod in IF_HTTP_SERVER, there is only a method SEND_PAGE but I am not sure this is the right one.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Kind regards,&lt;/P&gt;&lt;P&gt;Konstantinos&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 15 Jun 2015 13:30:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/http-request-handler-send-response/m-p/11112725#M1904185</guid>
      <dc:creator>konstantinos_vassiliadis</dc:creator>
      <dc:date>2015-06-15T13:30:03Z</dc:date>
    </item>
    <item>
      <title>Re: Http request handler - Send response</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/http-request-handler-send-response/m-p/11112726#M1904186</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Not sure if it helps or not. But a pointer may be.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Did you check class CL_HTTP_SERVER method SEND_RESPONSE .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This class has used the interface IF_HTTP_SERVER , so ideally you can cast the instance of IF_HTTP_SERVER and call the method . &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;R&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 15 Jun 2015 15:25:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/http-request-handler-send-response/m-p/11112726#M1904186</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2015-06-15T15:25:45Z</dc:date>
    </item>
    <item>
      <title>Re: Http request handler - Send response</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/http-request-handler-send-response/m-p/11112727#M1904187</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks a lot Rudra!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;however I have the following code, not sure how to do it properly&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;* the following line is the importing parameter to class which is the http request handler&lt;/P&gt;&lt;P&gt;* and thus implements interface IF_HTTP_EXTENSION&lt;/P&gt;&lt;P&gt;* SERVER TYPE REF TO IF_HTTP_SERVER&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;FIELD-SYMBOLS&lt;/SPAN&gt;&lt;SPAN class="L0S55"&gt;: &lt;/SPAN&gt;&amp;lt;ls&amp;gt; &lt;SPAN class="L0S52"&gt;type &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;REF &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;TO &lt;/SPAN&gt;CL_HTTP_SERVER&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;................&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;&lt;SPAN class="L0S52"&gt;ASSIGN &lt;/SPAN&gt;server &lt;SPAN class="L0S52"&gt;to &lt;/SPAN&gt;&amp;lt;ls&amp;gt; CASTING.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;which gives error when activating:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;"&amp;lt;LS&amp;gt;" and "SERVER" contain references, internal tables, or strings. In&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;the current statement, these must occur at the same offset position and&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;they must be compatible.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;How can I properly cast SERVER to type &lt;SPAN style="font-size: 13.3333330154419px;"&gt;CL_HTTP_SERVER so that I use SEND_RESPONSE method?&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;Konstantinos &lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Jun 2015 07:15:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/http-request-handler-send-response/m-p/11112727#M1904187</guid>
      <dc:creator>konstantinos_vassiliadis</dc:creator>
      <dc:date>2015-06-16T07:15:33Z</dc:date>
    </item>
    <item>
      <title>Re: Http request handler - Send response</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/http-request-handler-send-response/m-p/11112728#M1904188</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;FYI I used the following code&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; data:&amp;nbsp; lcl_cl_http_server &lt;SPAN class="L0S52"&gt;type &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;REF &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;TO &lt;/SPAN&gt;cl_http_server&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;.......................&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp; lcl_cl_http_server ?= server&lt;SPAN class="L0S55"&gt;.&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; "&amp;lt;-- widening cast&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;CLEAR&lt;/SPAN&gt;&lt;SPAN class="L0S55"&gt;: &lt;/SPAN&gt;lv_rc&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;CALL &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;METHOD &lt;/SPAN&gt;lcl_cl_http_server&lt;SPAN class="L0S70"&gt;-&amp;gt;&lt;/SPAN&gt;SEND_RESPONSE&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; RECEIVING&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; RC&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S55"&gt;= &lt;/SPAN&gt;lv_rc&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;and it seems to have worked (lv_rc is returned zero and the response was sent to client)&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Jun 2015 08:33:47 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/http-request-handler-send-response/m-p/11112728#M1904188</guid>
      <dc:creator>konstantinos_vassiliadis</dc:creator>
      <dc:date>2015-06-16T08:33:47Z</dc:date>
    </item>
    <item>
      <title>Re: Http request handler - Send response</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/http-request-handler-send-response/m-p/11112729#M1904189</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yeah, That is the way to cast using "?=" in ABAP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Glad to hear it worked.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 16 Jun 2015 09:05:38 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/http-request-handler-send-response/m-p/11112729#M1904189</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2015-06-16T09:05:38Z</dc:date>
    </item>
  </channel>
</rss>

