Repository navigation
feat(storage): expose highWaterMark option for File stream operations - #9705
thiyaguk09 wants to merge 25 commits into
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces support for configuring the stream highWaterMark (in bytes) for both readable and writable streams. It adds the highWaterMark option to CreateWriteStreamOptions, CreateReadStreamOptions, and MakeWritableStreamOptions, ensuring it is correctly propagated to underlying streams, including PassThroughShim, Writable, duplexify, and ProgressStream, as well as resumable and simple uploads. Comprehensive unit tests have been added to verify this propagation. There are no review comments, and I have no feedback to provide.
# Conflicts: # handwritten/storage/src/file.ts # handwritten/storage/src/nodejs-common/util.ts # handwritten/storage/test/file.ts # handwritten/storage/test/nodejs-common/util.ts
Dhriti07
left a comment
There was a problem hiding this comment.
Presubmits are failing for this PR. Please take a look
@Dhriti07 All Node 22/24/26 unit tests (Linux & Windows), This is pre-existing on We can track/fix the Bun fake-timer issue separately so we keep this PR scoped! |
@google-cloud/storageaccepts and propagates thehighWaterMarkoption onFile#createReadStreamandFile#createWriteStream(including simple uploads viaProgressStreamand the returnedWritablestream).Default stream buffering when
highWaterMarkis omitted, internal glue stream buffering, and resumable upload behavior remain unchanged.