0

How exactly does Highland.js implement backpressure? I'm curious about this.

resgh
  • 974
  • 2
  • 12
  • 22

1 Answers1

1

https://github.com/caolan/highland/blob/2.6.0/lib/index.js#L808

It looks like consumers ask the stream they are consuming to check any other consumers it may have every so often. If any of those consumers are in the paused state, the parent stream pauses as well.

amsross
  • 453
  • 2
  • 12