wandenberg / nginx-push-stream-module

A pure stream http push technology for your Nginx setup. Comet made easy and really scalable.
Other
2.22k stars 295 forks source link

push_stream_events_channel_id: End each chunk data with CRLF sequence #205

Closed zubinmehta closed 9 years ago

zubinmehta commented 9 years ago

On subscribing to push_stream_events_channel_id for events, each chunk of JSON ( as the response has Transfer-Encoding: chunked ) should return data ending with CRLF sequence. Currently, I think it isn't doing that.

wandenberg commented 9 years ago

Why are you saying that? The response on that channel has the same format as any other, use the same code.

zubinmehta commented 9 years ago

Basically, I was trying to use something like this: http://www.python-requests.org/en/latest/user/advanced/#streaming-requests at my backend to keep track of who is online, but it wasn't working as it was unable to get lines (no line ending encountered) as there was no CRLF end sequence as required: https://en.wikipedia.org/wiki/Chunked_transfer_encoding#Format

So I am unable to work with it.

PS: I might be wrong here or it could be a python-requests quirk that I am not aware of !

zubinmehta commented 9 years ago

It is due to an issue related with python-requests -> https://github.com/kennethreitz/requests/issues/2433

Closing this issue.