on 02-03-2017 11:38 AM
Dear All.
Please find my scenario snapshot
Requirement is:
when we receive the incoming payload we need post the records to Odata.
the validation is:
before posting we need to check the Odata service whether it's exist or not. if records are exist we need send a mail saying that 'the records already exist' else we need to post the records to Odata.
the validation result is:
if the records are exist in Odata i'm getting a records from Odat like below
<Invoices>
<Invoice>
<BuyerID/>
<VendorName>Roield</VendorName>
<VendorNo>4716001571</VendorNo>
<StatusID>01</StatusID>
<InvoiceNo>R20</InvoiceNo>
<StatusDesc>Received</StatusDesc>
<InvoiceAmt>-144309</InvoiceAmt>
<InvoiceDate>2016-10-31T13:51:39.000</InvoiceDate>
<Currency>INR</Currency>
<BuyerName>Technologies Private Limited</BuyerName>
</Invoice>
</Invoices>
if the records are not exist, i'm getting an response value from OData like below
<Invoices/>
And the condition which i placed is working fine is working fine.
the issue is:
when , if the records are not available in OData we need to post the actual incoming payload, but the condition passing the value only <Invoices/> .
how can i get the actual payload here.
please suggest further.
Regards
Ramesh
Hello Ramesh,
Its very easy to do using Properties and content Modifier .
1 ) You need to include 2 content Modifier like below one to store and another to restore.
First Content Modifier:
Set the property to hole incoming message ( ${in.body} ).
Second Content Modifier:
Call the property set before Request Reply to Body part which will restore the original message.
Regards,
Sriprasad Shivaram Bhat
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Sriprasad,
I followed the same steps and created an iflow with exception subprocess. In exception subprocess I am calling the property to restore the payload. So this should log the incoming payload only in case if the message fails. But I am getting below error if I click on the 'payload' tab in message processing log. Also its not logging any payload. Could you please help me with your inputs and suggestoons.
Thanks,
Ashwini
Hello Ramesh,
There is no difference between ${body} and ${in.body} as per the Apache Documentation both of them refers to input message body.Similarly there is some thing called ${out.body} which refers to output body.
From SAP HCI perspective we use input message expressions more.
Regards,
Sriprasad Shivaram Bhat
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you Sri. it's working.
i can see ${body} and {in.body} is working fine in property value. is there any differences.
Regards
Ramesh
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
90 | |
10 | |
10 | |
10 | |
7 | |
7 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.