Open jbt00000 opened 4 years ago
I just performed a test...
Turned on gateway mode.
Re-ran in fiddler after adding the header
[Accept-Encoding: gzip, deflate]
My upsert worked, but Cosmos server ignored by compression request.
You may still want to add that header when in Gateway mode hoping for the eventual server side support, but then bang away at the server team to add that feature. It would make a big difference when either performing bulk operations or when people use large docs.
As I just wrote a function that triggers off of changes in Cosmos, I'm seeing this as yet another place where compressing the payload will make a HUGE performance difference when compression is turned on and if documents have any size at all OR if there is a large rate of change.
I'm performing a tiny little export of 10K records from Cosmos. Each of my records is ~300KB. data from Cosmos. So, that's 3.5GB. After it got to my hard drive, I zipped it and it was 340MB. That amounts to a significant bandwidth savings and speedups. Imagine what that would do for your performance metrics...
Compression should not happen during HTTP calls only. We should also have the ability to store compressed data. I saw https://feedback.azure.com/forums/263030-azure-cosmos-db/suggestions/19164487-compress-stored-data#{toggle_previous_statuses}. Any ETA on this? @j82w
Compression should not happen during HTTP calls only. We should also have the ability to store compressed data. I saw https://feedback.azure.com/forums/263030-azure-cosmos-db/suggestions/19164487-compress-stored-data#{toggle_previous_statuses}. Any ETA on this? @j82w
That link is broken. Also interested though.
its been three years it would be great if this request is taken into consideration
Another issue with performance is the payloads (both request and response) in http mode (I did not sniff to verify TCP/IP mode), is the json is uploaded in plain text.
It should be compressed... and possibly delivered in other forms like bson. Both would cut payload size and therefore improve performance.
Compression would be initiated on demand via options or in automatic mode based on payload size.