Skip to content

Commit

Permalink
Added HttpContentDecompressor to HttpBlobStore download pipeline. baz…
Browse files Browse the repository at this point in the history
  • Loading branch information
excitoon committed Jun 25, 2019
1 parent ac3d06b commit 45695c5
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
import io.netty.channel.socket.nio.NioSocketChannel;
import io.netty.channel.unix.DomainSocketAddress;
import io.netty.handler.codec.http.HttpClientCodec;
import io.netty.handler.codec.http.HttpContentDecompressor;
import io.netty.handler.codec.http.HttpHeaderNames;
import io.netty.handler.codec.http.HttpObjectAggregator;
import io.netty.handler.codec.http.HttpRequestEncoder;
Expand Down Expand Up @@ -342,6 +343,7 @@ private Future<Channel> acquireDownloadChannel() {
"timeout-handler",
new IdleTimeoutHandler(timeoutSeconds, ReadTimeoutException.INSTANCE));
p.addLast(new HttpClientCodec());
p.addLast("inflater", new HttpContentDecompressor());
synchronized (credentialsLock) {
p.addLast(new HttpDownloadHandler(creds));
}
Expand Down Expand Up @@ -372,6 +374,7 @@ private void releaseDownloadChannel(Channel ch) {
try {
ch.pipeline().remove(IdleTimeoutHandler.class);
ch.pipeline().remove(HttpClientCodec.class);
ch.pipeline().remove(HttpContentDecompressor.class);
ch.pipeline().remove(HttpDownloadHandler.class);
} catch (NoSuchElementException e) {
// If the channel is in the process of closing but not yet closed, some handlers could have
Expand Down

0 comments on commit 45695c5

Please sign in to comment.