cancel
Showing results for 
Search instead for 
Did you mean: 

How we are getting performence Issue in Framework Expand ? How we are going to overcome through Data Provider Expand?

hussain_p
Participant
0 Kudos

Hi All

How we are getting performence Issue in Framework Expand ?

How we are going to overcome through Data Provider Expand?

Please help me to resolve my doubt.

Thanks in Advance.

Accepted Solutions (1)

Accepted Solutions (1)

former_member184867
Active Contributor
0 Kudos

Gateway framework generic expand by default. This does not require any development effort. But is is not good from performance perspective. Let's take the example

https://<server>:<port>/.../<service_name>/SalesOrders?$expand=SalesOrderItems

Let's assume you have 10 Sales Orders in your system and each of the sales order has 3 SalesOrderLineItems. To answer the above query Gateway Framework

  1. calls the GET_ENTITYSET implementation for Sales Orders 10 times.
  2. For each Sales Order retrieved by the GET_ENTITYSET implementation, the framework calls the related GET_ENTITYSET implementation for the items in a LOOP. That means you call the FM total 30 times.

So in total you make 10+30=40 database calls.

Now let's assume you have an optimised function module that can return the data in one call. In this case you can utilize the GET_EXPANDED_ENTITY or GET_EXPANDED_ENTITYSET of the DPC where you call the function module and return the data. In this case the GW framework does not make unnecessary Database calls. This makes your performance much better.

Answers (2)

Answers (2)

hussain_p
Participant
0 Kudos

Thank u Mallik.

I have checked through debugging,what ever you gave that statements are correct.

ChandraMahajan
Active Contributor
0 Kudos

In addition, check my blog and try to implement it both ways and see the performance improvement.

-Chandra