Open t1707 opened 6 years ago
Thanks. Yes, supporting this makes sense when/if Jetty adds support.
Jetty already supports static / pre-compressed brotli served from the standard DefaultServlet
.
There is currently no performant Brotli implementation for Java, which makes dynamic support difficult.
@joakime
There is currently no performant Brotli implementation for Java, which makes dynamic support difficult.
Yes, agreed but I think that implementing JNI wrapper for Vespa would work too. As Pure Java version for decoding, is already available and writing wrapper for encoding shouldn't have that much affect over the performance.
JNI is a PITA so I'd rather wait for somebody to write a pure Java implementation.
brotli compression algorithm (developed by Google) is considerably better in performance aspects(both speed and compression ratio) than gzip for both static and on-the-fly compressions.
I tried adding patch for brotli support but it seems like jdisc is built on jetty and as of now, jetty doesn't have any brotli support for dynamic requests(which is mostly the case for Vespa). I have created a separate issue here https://github.com/eclipse/jetty.project/issues/2553.
I think it's better to have support for brotli in Vespa. But it would be great to hear some comments from Vespa community?