on 07-07-2011 9:13 AM
An external partner has a calling interface that sends a HTTP-Redirect to a specific application-url and transfers all the data in one POST-Parameter.
The value of this POST-Paramater (CALLINTERFACE) consists the XML-Data.
<form id='InterfaceData3' method='post' action='/ProduktFrontController/Start'>
<textarea cols="80" rows="30" name='CALLINTERFACE'><?xml version="1.0" encoding="UTF-8"?>
<authentifizierung version="1.0">
XML-Data.....
</authentifizierung>
<br>
<p><input id='button1' type='submit' name='Button' value='Absenden'></p>
</form>
Standard-Java:
In our Java-Application we can read the POST-Value (XML-Data) via the HTTPServletRequest-Object/Instance.
WebDynPro-Java:
IWDProtocolAdapter protocolAdapter = WDProtocolAdapter.getProtocolAdapter();
IWDRequest request = protocolAdapter.getRequestObject();
String xmlData = request.getParameter("CALLINTERFACE");
In WebDynPro for ABAP I couldnt find a equivalent solution /technic to read the POST-Parameter-Value.
So I have to write a lot of annoying 'glue-code':-( (HTTP-Request-Handler for reading, Shared Memory / Objects for transfer to WebDynPro ABAP),
(Remark: It's no solution to transfer XML-Data via a URL-Parameter because it is too big (> 1 KByte) and the external partner doesn't support this option!).
My questions:
1) What technics for transfering Data (not only 2 or 3 Parameter) form external web-applications into WebDynPro ABAP applications does SAP support?
2) Is it possible to reach the calling HTTP-Request from WebDynPro-ABAP? (MayBe via ABAP-Callback-Functions)
Sincerely
Steffen
Hi Steffen,
In order to receive the XMl data you need to do below ABAP work:
1) Create a Transformation for the XML using the STRANS tcode.
2) You can have an FM which receives the XML as string and calls the above transformation to convert the XML to an internal table.
In this way you can have all the XML data coming in an internal table which you can bind to a node.
I hope it helps.
Regards,
Sumit
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
thank you for your answers:-)
In conclusion the result is:
1) There is no "direct" way to read POST-Parameter in WebDynPro ABAP
=> You have to write a wrapper in BSP or an ICF - HTTP_REQUEST_HANDLER
(A ABAP-Class that implements the Interface "IF_HTTP_EXTENSION"
that reads the POST-Parameter-Value and transfers the value into a reachable localtion for WebDynPro-Abap.
2) For parsing the XML-Data I can use for example STRANS tcode or Simple Transformations
3) For transfering the Data between the BSP / the Request-Handler and WebDynPro for ABAP, I can use for example SharedMemory, Shared Objects.
Regards
Steffen
Edited by: Steffen Spahr on Jul 19, 2011 8:35 AM
Edited by: Steffen Spahr on Jul 19, 2011 8:55 AM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Steffen
have a look at the following thread.
this is possible in WDA but this is not encouraged.
suggestion would be to create a wrapper BSP application and read the xml data from the HTTP request and then invoke the webdynpro application by passing te xml data as URL parameter/ or by storing it locally
BR, Saravanan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
84 | |
24 | |
12 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.