hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gary Gregory <garydgreg...@gmail.com>
Subject [PROPOSAL] Extending HttpClient content decoders
Date Mon, 08 May 2017 17:59:08 GMT
Hi All,

We recently had a request to support Google's Brotli decompression

We decided NOT to add a dependency on the Brotli jar and I suggested that
the patch be provided against Apache Commons Compress, which was kindly
done and will be part of its upcoming 1.14 release.

For HttpClient to benefit from this, I see content decoders being picked up
from a Java Service Loader instead of hard coded.

The steps I see (and that I am volunteering to do) are:
- Refactor HttpClient to pick up content decoders through a ServiceLoader.
HC will find its own GZIP and DEFLATE decompressors this way.
- Create a new module called httpclient5-compress which will provide
decompressors as supported by Apache Commons Compress.

This will allow users to benefit from all Commons Compress algorithms
automatically if they put this new module in their POM.

Some details are to be worked out of course ;-) I see the default behavior
to stay unchanged for now WRT to what decoders a client is configured which
currently are gzip, z-gzip, and deflate.


E-Mail: garydgregory@gmail.com | ggregory@apache.org
Java Persistence with Hibernate, Second Edition

JUnit in Action, Second Edition

Spring Batch in Action
Blog: http://garygregory.wordpress.com
Home: http://garygregory.com/
Tweet! http://twitter.com/GaryGregory

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message