DynmapCore icon indicating copy to clipboard operation
DynmapCore copied to clipboard

gzip for update xhr calls?

Open sarahsturgeon opened this issue 6 years ago • 0 comments

Is there any way to configure jetty to compress the /up responses (which are only text) with gzip?

They're the biggest and slowest calls on the page, and I know it only happens a few times a second, but we could achieve notable compression with gzip.

Most browsers will send these headers along which, if we can modify jetty here, should make this pretty easy:

Accept: application/json
Accept-Encoding: gzip, deflate

I'm not a Java dev so please forgive me, but I found this old article which could demonstrate how to enable gzip compression if we're actually able to configure it at all: https://blog.max.berger.name/2010/01/jetty-7-gzip-filter.html

sarahsturgeon avatar Dec 13 '18 10:12 sarahsturgeon