Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion store/src/core/chunks.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// The most statements in one request, as `docs/specs/renders.md` -> Requests says. It holds 19,600 renders, so a batch of up to that many costs one.
// The most statements in one request, as `docs/specs/renders.md` -> Requests says. With a statement per 1,000 stories to key them, it holds about 18,600 renders, so a batch of up to that many costs one.
export const STATEMENTS_PER_REQUEST = 400;

/** Splits items into groups of at most `size`, in order. */
Expand Down
2 changes: 1 addition & 1 deletion store/test/render-batches.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ describe("RenderBatches", () => {
});

describe("crashes partway", () => {
// 19,600 renders fill the 400 statements of one request, so this takes two.
// 20 statements key the stories and 380 hold 18,620 renders, filling the 400 statements of one request, so this takes two.
const RENDERS = 20_000;
const items: RecordedRender[] = Array.from({ length: RENDERS }, (_, i) =>
rendered(`story-${i}`, (i % 40) + 1),
Expand Down
Loading