Skip to Content
0

Debug Option for $batch Odata Calls

Jan 12, 2017 at 03:23 PM

413

avatar image

Hello Everybody,

we are currently migration old SAP UI5 Applications in a new tool. We would like to use the Odata-Services used in the standard. Unforunally SAP used $batch to conslidate the odata calls to the backend. But we want to see which services are called with parameters etc.

Is there a oportunity to disable batch for debugging purposes. We are aware of the option to diable batch on the model, but we can't do this because the applications are in SAP namespace and we can't change them without modification key.

Is there a browser-parameter or do we have options in the SAP Backend?

Thank you in advance.
Moritz

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

Best Answer
Radek Chudziak Jan 12, 2017 at 04:27 PM
1

Just an idea you may try. Put a breakpoint somewhere in the code where you can access the model and try to disable batch processing in the Chrome's developer console.

e.g. in the console write:

var oModel = this.getModel();
oModel.setUseBatch(false);
Show 1 Share
10 |10000 characters needed characters left characters exceeded

This actually works. I`ve added a breakpoint to the component.js-File and executed via console:

this .getModel("{YOUR MODEL NAME}").setUseBatch(false);

If you`ve instanciated your model in the code, set the breakpoint after the creation of the model.

@Radek, thank you for your help!

1
Jun Wu Jan 12, 2017 at 04:52 PM
0

you cannot see from network tab of your browser developer tool?

Show 2 Share
10 |10000 characters needed characters left characters exceeded

You`ll only see the batch call, but not which services are called (see screen).
But Radek suggested a working solution.

chrome.png

chrome.png (32.0 kB)
0

if you click, you should be able to see the detail

0