dwave-cloud-client icon indicating copy to clipboard operation
dwave-cloud-client copied to clipboard

Add config parameter to control if compression is accepted in API responses

Open randomir opened this issue 5 years ago • 0 comments

On fast networks, it's preferable to turn compression off with Accept-Encoding: identity header on all requests to SAPI.

Accepting gzip encoding (current default) will slow-down encoding/transmission on SAPI side, and slow down the overall download by factor of 2 to 5. This is most prominent during "solver definition fetch" while selecting solver by features, because then we must download definitions of all solvers (order of MiB).

On slow networks, it's better to leave the server-side compression.

Note: this can already be done through DWAVE_API_HEADERS env var and headers config option/kwarg, but the exact HTTP header has to be specified.

randomir avatar Aug 28 '20 21:08 randomir