Skip to content

feat(firestore): Add support for 16MB documents - #8649

Merged
dlarocque merged 4 commits into
mainfrom
dl/largedoc
Jul 13, 2026
Merged

feat(firestore): Add support for 16MB documents#8649
dlarocque merged 4 commits into
mainfrom
dl/largedoc

Conversation

@dlarocque

@dlarocque dlarocque commented Jun 15, 2026

Copy link
Copy Markdown
Contributor
  • Adds support for 16 MB documents in Firestore by increasing the gRPC message size limit to 17MB.
  • Increases gRPC flow control window default from 64 KB to 256 KB, to reduce latency for large document reads.

If a regression is introduced by increasing the flow control window, this can be overwritten:

const firestore = new Firestore.Firestore({ 
  // ...
  grpcOptions: { 'grpc-node.flow_control_window': 64 * 1024 }
});

@product-auto-label product-auto-label Bot added the api: firestore Issues related to the Firestore API. label Jun 15, 2026

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the Firestore client to support larger documents by increasing the gRPC max receive and send message lengths to 17MB and configuring flow control window sizes. It also adds a new integration test suite (large_document.ts) to verify handling of large documents (up to 15.9MB) and rejection of oversized payloads. The review feedback correctly identifies an issue in the oversized payload test where a successful write would throw a generic error that gets caught and fails on an unrelated assertion, masking the true failure; a cleaner assertion pattern is suggested.

Comment thread handwritten/firestore/dev/system-test/large_document.ts
@dlarocque
dlarocque marked this pull request as ready for review July 13, 2026 12:31
@dlarocque
dlarocque requested a review from a team as a code owner July 13, 2026 12:31
@dlarocque
dlarocque requested a review from wu-hui July 13, 2026 12:34
@dlarocque
dlarocque merged commit ecf348b into main Jul 13, 2026
34 of 36 checks passed
@dlarocque
dlarocque deleted the dl/largedoc branch July 13, 2026 18:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: firestore Issues related to the Firestore API.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants