Skip to content
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

What stream should I use for rate limiting (i.e. for object mode)? #27

Closed
sprijk opened this issue Mar 3, 2018 · 3 comments
Closed

Comments

@sprijk
Copy link

sprijk commented Mar 3, 2018

No description provided.

@bcomnes
Copy link
Collaborator

bcomnes commented Mar 5, 2018

I think just setting the high water mark will pause stream consumption in object mode. See https://nodejs.org/api/stream.html#stream_buffering

One type of throttling you can add in though, is https://github.com/maxogden/byte-stream which lets you batch up streams by count and time in object mode, or byte count + time not in object mode.

@bcomnes bcomnes closed this as completed Mar 5, 2018
@bcomnes bcomnes reopened this Mar 5, 2018
@bcomnes
Copy link
Collaborator

bcomnes commented Mar 5, 2018

Didn't mean to close, but please close if that answers your questions.

@bcomnes bcomnes closed this as completed Mar 8, 2018
@bcomnes
Copy link
Collaborator

bcomnes commented Mar 8, 2018

Closing. Speak up if there are unaddressed issues.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants