Error due to large response payload size at Apigee

Not applicable

Hi,

I have a backend service which is a passthrough service and hits the backend service without any transformation and sends response to client as is.

Here when I'm hitting a back end service and the response received is large in size as 7MB or more some times. Due to this, error is being thrown at client end. When the response size is lessthan 1MB(which we tested), we are able to see results as expected. However problem occurs when the response size is huge

Can we achieve by large response handling by using Streaming? If its the case how can we achieve it.

If we cannot store whole response using streaming, how can we store partial data at least.

Can you please help me here with the above issue I'm facing.

Thanks in advance.

Solved Solved
0 1 1,717
1 ACCEPTED SOLUTION

Not applicable

The HTTP request and response that flow through Apigee Edge are always stored in a buffer to enable the policies to operate on the payload. The buffer size on Apigee cloud is 10 MB and 3MB for private cloud. In such cases, the only option to handle response payloads greater than the buffer size is to enable streaming. However, if you enable streaming; the policies defined in the TargetEndpoint flow will be bypassed since the payload cannot be read into the buffer. The link for streaming documentation is here.

If you do not want to stream, you could look at enforcing pagination by using offset+limit to restrict the number of records that can be queried in a single API call

View solution in original post

1 REPLY 1

Not applicable

The HTTP request and response that flow through Apigee Edge are always stored in a buffer to enable the policies to operate on the payload. The buffer size on Apigee cloud is 10 MB and 3MB for private cloud. In such cases, the only option to handle response payloads greater than the buffer size is to enable streaming. However, if you enable streaming; the policies defined in the TargetEndpoint flow will be bypassed since the payload cannot be read into the buffer. The link for streaming documentation is here.

If you do not want to stream, you could look at enforcing pagination by using offset+limit to restrict the number of records that can be queried in a single API call