Really struggling to get the Android client (uses ...
# ktor
n
Really struggling to get the Android client (uses Ktor Client) to obtain data (via a HTTP POST) from the server (uses Ktor Server) without the client showing a timeout or connection reset. The average size of the response body (JSON data) that the client should receive is around 1.3 MB (works using Postman). Is there a way to buffer the response body? Is compression enabled by default with Ktor Server?
👀 1
Managed to resolve the issue by enabling Gzip compression on the server end. Still have very long response times (around 1 min) which only occur if a request is made by the Android client. Very strange since the response times (around 1300 ms with the body containing about 500 items) are much quicker with a request made by the CLI client (uses Ktor CIO client) or Postman.
e
Hi @napperley, could you provide the example?
n
Unfortunately the sub projects (Server, Android client, CLI client) are part of a big commercial project.
👀 1