Skip to content

nromito/backpressure-transform

Repository files navigation

Backpressured Transform

A lib for automatically handling backpressure in NodeJS Transforms.

Example usage:

new BackpressureTransform({
  highWaterMark: 42,
  transform: (chunk, encoding) => chunk + chunk,
  flush: () => 'end'
})

The transform exposes the same Transform options that NodeJS provides besides transform() and flush(). These functions in BackpressureTransform return the transformed data and the BackpressureTransform handles when to execute the Transform callback to signal more data can be processed.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published