0

I am trying to decode the bytes in the contents of an HTTP response into a series of records. I was hoping to use the ReplayingDecoder in the following pipeline HttpResponseDecoder -> ReplayingDecoder. However, I cannot since ReplayingDecoder.decode() expects a ByteBuf, but the HttpResponseDecoder produces HttpContent objects. Is there any way to use a ReplayingDecoder in this context?

4

1 回答 1

0

只需使用 HttpObjectAggregator。这将确保您只接收在 ByteBuf 中保存完整有效负载的 FullHttpResponse 对象。

于 2013-11-13T05:15:19.000 回答