Skip to Content
avatar image
Former Member

Pass Request message Value To Response message

Hi Experts,

I have a requirement to pass a value from request to response

I have successfully achieved this using below blogs

Actual Requirement : Client is asking to send the value back in response even in the case of message mapping error, lets says if a condition fails due to bad/wrong value that value should be passed on to response and send it back to client

When message mapping error occurs, message processing stops and does NOT go further till RFC receiver channel to execute put and get payload beans modules

How do i achieve this

Is there anyway where i can check value and if it is wrong pass it immediately to response with out sending it further to receiver channel

https://blogs.sap.com/2013/03/20/insert-value-from-request-message-to-response-using-getpayloadvaluebean-and-putpayloadvaluebean/

https://blogs.sap.com/2015/08/28/copy-value-from-request-message-to-response-message-using-dynamicconfigurationbean-and-dynamic-header-fields/

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Sep 21, 2017 at 09:00 AM

    Hi Gaurav!

    What is your scenario type? Is it synchronous or do you use async-sync bridge?

    Regards, Evgeniy.

    Add comment
    10|10000 characters needed characters exceeded

  • Sep 22, 2017 at 07:26 PM

    Hi Gaurav!

    In case of sync-async bridge is used you can try approach when you check required field's value in Receiver determination and if it's wrong - send message to separate receiver with its own message mapping to build fault data response. And you use communication channel for that receiver in which you add NotifyResponseBean module and remove default module. Thus you close synchronous request with fault response.

    Regards, Evgeniy.

    Add comment
    10|10000 characters needed characters exceeded