New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Simplify stream classes #2555

Closed
asvetlov opened this Issue Nov 24, 2017 · 5 comments

Comments

Projects
None yet
2 participants
@asvetlov
Member

asvetlov commented Nov 24, 2017

  • drop ChunksQueue -- not used by aiohttp code
  • drop FlowControlChunksQueue -- not used by aiohttp code
  • Merge FlowControlStreamReader into StreamReader, drop FlowControlStreamReader. The reader without flow control is not used by aiohttp, FlowControlStreamReader is too long name. Getting rid of await super() calls may boost performance a little.
  • Add hysteresis to StreamReader to prevent flipping between paused and resumed states too often.
@kxepal

This comment has been minimized.

Member

kxepal commented Nov 24, 2017

FlowControlChuckQueue is useful when server emits item-per-chunk - that's quite handy to process. CouchDB does that for instance. Let me check if this approach is still actual.

@asvetlov

This comment has been minimized.

Member

asvetlov commented Nov 24, 2017

If CouchDB needs FlowControlChuckQueue -- please copy the implementation into the project.
Supporting not used classes is a burden, you know.

@kxepal

This comment has been minimized.

Member

kxepal commented Nov 24, 2017

Not a problem, I know (: Probably, that even wouldn't be need after switching to ijson.

@kxepal

This comment has been minimized.

Member

kxepal commented Nov 24, 2017

Just wanted to describe the case when that flow was useful. Some else users eventually may use it as well.

@asvetlov

This comment has been minimized.

Member

asvetlov commented Nov 25, 2017

Fixed by @2256

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment