-
-
Notifications
You must be signed in to change notification settings - Fork 8
Implement flux generator #5
Copy link
Copy link
Open
Labels
help wantedExtra attention is neededExtra attention is needednew featureNew feature or requestNew feature or request
Metadata
Metadata
Assignees
Labels
help wantedExtra attention is neededExtra attention is needednew featureNew feature or requestNew feature or request
Right now, this project only implements the flux
Transformerwhich allows you to "transform" a stream from one form to another by passing it through a promise-based API.This package should also provide a flux
Generatorwhich allows you to "generate" a stream of data from a promise-based API. A common use case would be to generate a stream of "user" objects from a database client that always fetches X users at once.By passing this stream into the existing
Transformer, it would automatically take care of throttling theGeneratorto pause fetching new entries when the concurrency limit is reached and will automatically resume fetching once the outstanding operations have been fulfilled. It could thus effectively be used a form of a lightweight message queue.