--
You received this message because you are subscribed to the Google Groups "Nginx-Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nginx-clojure+unsubscribe@googlegroups.com.
To post to this group, send email to nginx-...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/nginx-clojure/ddb38755-013a-4909-a840-6c44ffaf38e1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Date: Fri, 07 Jul 2017 12:22:53 GMT
Content-Type: application/vnd.hp-pcl
Transfer-Encoding: chunked
Connection: close
Vary: Accept-Encoding
Server: nginx-clojure/0.4.3
X-my-header-L: my-header-content-L
..............................
.........................................................................................2bdc6
Curl gives the below output
{ [data not shown]
* Problem (2) in the Chunked-Encoded data
0 0 0 0 0 0 0 0 --:--:-- 0:00:04 --:--:-- 0
* Closing connection 0
curl: (56) Problem (2) in the Chunked-Encoded data
Hi,NginxHttpServerChannel.write is of the low level APIs and only send the raw data to the client, e.g. websocket data.Please try the high level API such as NginxHttpServerChannel.sendHeader/send/sendBody, e.g.NginxHttpServerChannel channel = r.hijack(false);channel.sendHeader(200, null, true, false);channel.send("first part.\r\n", true, false);channel.send("second part.\r\n", true, false);channel.send("third part.\r\n", true, false);channel.send("last part.\r\n", true, true);
On Thu, Jul 6, 2017 at 9:01 PM, vsen <senth...@gmail.com> wrote:
Hi,We have followed the implementation of StreamingWriteHandler fromWe are observing that data is written to the downstream in smaller byte array but we also observed that gzip and chunked transfer is not appliedi.e. we are are not seeing Transfer-Encoding : chunked in the response headerwith request.hijack(false) we were expecting that nginx will intercept the response and apply the filters like gzip, chunked transfer.Can anyone help us to achieve Chunked transfer , Gzip with Request hijackThanks in advancevsen
--
You received this message because you are subscribed to the Google Groups "Nginx-Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nginx-clojur...@googlegroups.com.
private void doWriteChunked(NginxHttpServerChannel serverChannel) throws IOException {
serverChannel.sendHeader(NGX_HTTP_OK,null,true, false);
serverChannel.send("FirstChunk.",true, false);
serverChannel.send("SecondChunk.",true, false);
serverChannel.send("ThirdChunk.",true, false);
serverChannel.send("LastChunk.",true, true);
}
Date: Tue, 11 Jul 2017 06:53:55 GMT
Content-Type: application/octet-stream
Transfer-Encoding: chunked
Connection: close
Server: nginx-clojure/0.4.3
X-my-header-L: my-header-content-L
FirstChunk.b
FirstChunk.
c
SecondChunk.
b
ThirdChunk.
a
LastChunk.
0
To unsubscribe from this group and stop receiving emails from it, send an email to nginx-clojure+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/nginx-clojure/af520761-e500-428e-a2c7-ae943c1bf134%40googlegroups.com.