react/fixtures
Sebastian Markbåge 969a9790ad
[Flight] Track I/O Entry for the RSC Stream itself (#34425)
One thing that can suspend is the downloading of the RSC stream itself.
This tracks an I/O entry for each Promise (`SomeChunk<T>`) that
represents the request to the RSC stream. As the value we use the
`Response` for `createFromFetch` (or the `ReadableStream` for
`createFromReadableStream`). The start time is when you called those.

Since we're not awaiting the whole stream, each I/O entry represents the
part of the stream up until it got unblocked. However, in a production
environment with TLS packets and buffering in practice the chunks
received by the client isn't exactly at the boundary of each row. It's a
bit longer into larger chunks. From testing, it seems like multiples of
16kb or 64kb uncompressed are common. To simulate a production
environment we group into roughly 64kb chunks if they happen in rapid
sequence. Note that this might be too small to give a good idea because
of the throttle many boundaries might be skipped anyway so this might
show too many.

The React DevTools will see each I/O entry as separate but dedupe if an
outer boundary already depends on the same chunk. This deduping makes it
so that small boundaries that are blocked on the same chunk, don't get
treated as having unique suspenders. If you have a boundary with large
content, then that content will likely be in a separate chunk which is
not in the parent and then it gets marked as.

This is all just an approximation. The goal of this is just to highlight
that very large boundaries will very likely suspend even if they don't
suspend on any I/O on the server. In practice, these boundaries can
float around a lot and it's really any Suspense boundary that might
suspend but some are more likely than others which this is meant to
highlight.

It also just lets you inspect how many bytes needs to be transferred
before you can show a particular part of the content, to give you an
idea that it's not just I/O on the server that might suspend.

If you don't use the debug channel it can be misleading since the data
in development mode stream will have a lot more data in it which leads
to more chunking.

Similarly to "client references" these I/O infos don't have an "env"
since it's the client that has the I/O and so those are excluded from
flushing in the Server performance tracks.

Note that currently the same Response can appear many times in the same
Instance of SuspenseNode in DevTools when there are multiple chunks. In
a follow up I'll show only the last one per Response at any given level.

Note that when a separate debugChannel is used it has its own I/O entry
that's on the `_debugInfo` for the debug chunks in that channel.
However, if everything works correctly these should never leak into the
DevTools UI since they should never be propagated from a debug chunk to
the values waited by the runtime. This is easy to break though.
2025-09-09 16:46:11 -04:00
..
art Bump canary versions to v19-canary (#28646) 2024-03-26 15:31:57 -04:00
attribute-behavior React DOM: Add support for Popover API (#27981) 2024-05-20 22:01:39 +02:00
concurrent/time-slicing Bump follow-redirects from 1.15.4 to 1.15.6 in /fixtures/concurrent/time-slicing (#28572) 2024-03-18 11:56:04 -04:00
devtools Rename "next" prerelease channel to "canary" (#26761) 2023-05-03 12:10:32 -04:00
dom Add scrollIntoView to fragment instances (#32814) 2025-08-27 18:05:57 -04:00
eslint-v6 feat(eslint-plugin-react-hooks): merge rule from eslint-plugin-react-compiler into react-hooks plugin (#32416) 2025-03-12 21:43:06 -04:00
eslint-v7 feat(eslint-plugin-react-hooks): merge rule from eslint-plugin-react-compiler into react-hooks plugin (#32416) 2025-03-12 21:43:06 -04:00
eslint-v8 feat(eslint-plugin-react-hooks): merge rule from eslint-plugin-react-compiler into react-hooks plugin (#32416) 2025-03-12 21:43:06 -04:00
eslint-v9 [compiler] Aggregate error reporting, separate eslint rules (#34176) 2025-08-21 14:53:34 -07:00
expiration Bump browserify-sign from 4.0.4 to 4.2.2 in /fixtures/expiration (#27600) 2023-11-01 19:31:28 +00:00
fiber-debugger Rename yarn start to yarn dev and yarn start:prod to yarn start (#26209) 2023-02-21 14:18:21 -05:00
fizz Clear bundler cache before bundling fixtures (#33426) 2025-06-03 21:10:13 +02:00
fizz-ssr-browser [UMD] Remove umd builds (#28735) 2024-04-17 11:15:27 -07:00
flight [Flight] Track I/O Entry for the RSC Stream itself (#34425) 2025-09-09 16:46:11 -04:00
flight-esm Clear bundler cache before bundling fixtures (#33426) 2025-06-03 21:10:13 +02:00
flight-parcel [Flight Parcel] Implement findSourceMapURL (#32294) 2025-02-04 14:17:13 -05:00
legacy-jsx-runtimes Bump braces from 3.0.2 to 3.0.3 in /fixtures/legacy-jsx-runtimes (#29844) 2024-06-11 11:36:36 -04:00
nesting docs: fix typo in fixtures/nesting/README.md (#27507) 2024-04-06 19:11:19 +02:00
owner-stacks Clear bundler cache before bundling fixtures (#33426) 2025-06-03 21:10:13 +02:00
packaging Bump browserify-sign from 4.0.4 to 4.2.2 in /fixtures/packaging/brunch/prod (#27598) 2023-11-01 19:30:25 +00:00
scheduler [flags] Delete enableSchedulerDebugger (#31826) 2024-12-18 13:29:22 -05:00
ssr [Fizz] If we haven't painted yet, wait to reveal everything until next paint (#34230) 2025-08-18 20:22:40 -04:00
ssr2 Bump canary versions to v19-canary (#28646) 2024-03-26 15:31:57 -04:00
stacks Bump braces from 3.0.2 to 3.0.3 in /fixtures/stacks (#29843) 2024-06-11 11:35:40 -04:00
view-transition Disable ScrollTimeline in Safari (#33499) 2025-07-02 17:01:49 -04:00