[Answered ]-Bypassing Cloud Run 32mb error via HTTP2 end to end solution

0👍

The Cloud Run HTTP response limit is 32 MB and cannot be increased.

One suggestion is to compress the response data. Django has compression libraries for Python or just use zlib.

import gzip
data = b"Lots of content to compress"
cdata = gzip.compress(s_in)
# return compressed data in response

1👍

Cloud Run supports HTTP/1.1 server side streaming, which has unlimited response size. All you need to do is use chunked transfer encoding.

https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Transfer-Encoding

👤wlhee

Leave a comment