end of stream
The point where a stream has no more data: a Readable emits end, and a Writable emits finish after end() has been called and all data flushed.
In more detail
A custom Readable signals it by calling this.push(null). Writing after end() is an error.
Related terms
- Readable stream — A Node.js stream you read data from, such as a file being read, an incoming HTTP request or a socket.
- Writable stream — A Node.js stream you write data to, such as a file being written, an HTTP response or a socket.
- readable.push() — The method a custom Readable or Transform stream calls to add a chunk to its output buffer.
Taught in
- Stream Mechanics: Readable Streams & Flowing Modes — Node.js Internals & Backend Services
- Writable Streams: Drain Events & highWaterMark — Node.js Internals & Backend Services