thefactory/marathon-python

Event streaming not realtime

Opened this issue · 1 comments

When I use event streaming and observe events I receive, I found events does not always arrive "realtime", usually the last message doesn't show up until the next batch of events.

I use wireshark to capture the traffic and found that marathon did send out events in real time, but requests just keeping holding the last message.

Then I did a little research and found that reqeusts.Response.iter_lines does not work in a realtime manner, using the default chunk_size.

See the issues under requests:
psf/requests#3577 (comment)

any ideas?