Skip to Content
avatar image
Former Member

Header Response in Batch Processing


My Scenario:

Multiple records update is required from the front end. This is achieved via Batch Processing. Upon processing of each record, an update message for each record should be sent back to UI5.


Need to send back the status message to UI for each single record.

Actual Process followed:

Lets say I have 3 records for updating, the sequence of methods called are as below:

1. Change Set BEGIN.

2. Update Entity (Called 3 times)

3. Change Set END.

In Begin method is just redefined and has no code.

In Update entity I am collecting all the individual record in an global internal table of same class.

In End method, calling an RFC to update all 3 records at a time. This RFC returns 3 messages indicating success or failure which needs to sent to UI.

Hence I thought to send these messages by concatenating into single message and send via Header response in method Change Set END as follows:

  1. data:  ls_header               TYPE ihttpnvp. 
  2. ls_header-name = 'my-custom-message' . 
  3. ls_header-value = 'my_message'. 
  4. /iwbep/if_mgw_conv_srv_runtime~set_header( ls_header ).


I am not getting any header response with name my-custom-message.

Kindly suggest me to send the messages to UI5 with any corrections to above procedure or an alternative procedure.

Note: The header response with above method is only working from method Update Entity and I don't want to call the RFC for each single entity.


Satish D R

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

2 Answers

  • Oct 28, 2015 at 11:04 AM

    Hello Satish,

    One question - Do you want a All or None behavior or partial success is also acceptable. In case you need all/none behavior then obviously you cannot call the RFC in every Update method and what you have designed is fine.

    One alternative way which we did was that append two additional columns - status code and message in the structure where you are storing the values from the UI for every update record and populate these structures and pass them back to UI. Now UI has the data at the row level and can choose to display a cumulative or individual status for every record.


    Add comment
    10|10000 characters needed characters exceeded

  • avatar image
    Former Member
    Nov 19, 2015 at 11:05 AM


    In some of the methods you call set_header?(create_entity get_entity...)

    Add comment
    10|10000 characters needed characters exceeded