Skip to content

perf(start-client-core): compact private frame decoder result keys - #7978

Draft
Sheraff wants to merge 3 commits into
mainfrom
codex/frame-decoder-compact-result
Draft

perf(start-client-core): compact private frame decoder result keys#7978
Sheraff wants to merge 3 commits into
mainfrom
codex/frame-decoder-compact-result

Conversation

@Sheraff

@Sheraff Sheraff commented Aug 6, 2026

Copy link
Copy Markdown
Collaborator

What changed

  • Rename the private createFrameDecoder result keys from getOrCreateStream/jsonChunks to getStream/chunks.
  • Update the sole production consumer and direct decoder tests in lockstep.
  • Keep the existing two-property object shape, function/stream identities, property order, and public exports unchanged.

Bundle impact

Across the full 17-scenario matrix, all 11 Start scenarios improve by 4–12 B gzip and 24 B raw; all six router-only scenarios are byte-identical. Both renames also improve independently on react-start.minimal: getStream saves 6 B gzip / 16 B raw, and chunks saves 1 B gzip / 8 B raw. Brotli is mixed and documented in the evidence report.

Validation

  • start-client-core frame-decoder unit suite: 19 passed
  • TypeScript 5.6, 5.7, 5.8, 5.9, 6.0, and 7.0 matrices passed
  • ESLint passed with no new errors
  • React Start Vite/SSR client-RPC RawStream e2e: 6 passed
  • Full 17-scenario bundle matrix passed
  • Runtime allocation/destructure benchmark found no directional change
  • Five independent bundle, runtime, API, integration, and codegen reviews approved

Detailed artifacts and attribution are recorded in RESULT-optimization-frame-decoder-compact-result.md.

@coderabbitai

coderabbitai Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro Plus

Run ID: 0f2423e3-d776-4ad0-b24b-32fd3d536b6d

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@nx-cloud

nx-cloud Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

View your CI Pipeline Execution ↗ for commit b0c4ab1

Command Status Duration Result
nx affected --targets=test:eslint,test:unit,tes... ✅ Succeeded 2m 46s View ↗

☁️ Nx Cloud last updated this comment at 2026-08-06 07:32:05 UTC

@github-actions

github-actions Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

🚀 Changeset Version Preview

5 package(s) bumped directly, 18 bumped as dependents.

🟩 Patch bumps

Package Version Reason
@tanstack/react-router 1.170.20 → 1.170.21 Changeset
@tanstack/router-core 1.171.17 → 1.171.18 Changeset
@tanstack/solid-router 1.170.20 → 1.170.21 Changeset
@tanstack/start-server-core 1.169.20 → 1.169.21 Changeset
@tanstack/vue-router 1.170.19 → 1.170.20 Changeset
@tanstack/react-start 1.168.37 → 1.168.38 Dependent
@tanstack/react-start-client 1.168.18 → 1.168.19 Dependent
@tanstack/react-start-rsc 0.1.36 → 0.1.37 Dependent
@tanstack/react-start-server 1.167.25 → 1.167.26 Dependent
@tanstack/router-cli 1.167.23 → 1.167.24 Dependent
@tanstack/router-generator 1.167.23 → 1.167.24 Dependent
@tanstack/router-plugin 1.168.25 → 1.168.26 Dependent
@tanstack/router-vite-plugin 1.167.25 → 1.167.26 Dependent
@tanstack/solid-start 1.168.36 → 1.168.37 Dependent
@tanstack/solid-start-client 1.168.18 → 1.168.19 Dependent
@tanstack/solid-start-server 1.167.25 → 1.167.26 Dependent
@tanstack/start-client-core 1.170.16 → 1.170.17 Dependent
@tanstack/start-plugin-core 1.171.28 → 1.171.29 Dependent
@tanstack/start-static-server-functions 1.167.21 → 1.167.22 Dependent
@tanstack/start-storage-context 1.167.19 → 1.167.20 Dependent
@tanstack/vue-start 1.168.35 → 1.168.36 Dependent
@tanstack/vue-start-client 1.167.21 → 1.167.22 Dependent
@tanstack/vue-start-server 1.167.25 → 1.167.26 Dependent

@github-actions

github-actions Bot commented Aug 6, 2026

Copy link
Copy Markdown
Contributor

Bundle Size Benchmarks

  • Commit: bc1051ffba6b
  • Measured at: 2026-08-06T03:58:03.700Z
  • Baseline source: history:697ebb6ddbd4
  • Dashboard: bundle-size history

The following scenarios have bundle-size changes compared with the baseline:

Scenario Current (gzip) Delta vs baseline Initial gzip Raw Brotli Trend
react-start.minimal 100.59 KiB -8 B (-0.01%) 100.45 KiB 312.26 KiB 87.51 KiB ███████▁▁▁▁▁
react-start.deferred-hydration 101.33 KiB -11 B (-0.01%) 100.48 KiB 313.64 KiB 88.03 KiB ███████▁▁▁▁▁
react-start.full 103.91 KiB -8 B (-0.01%) 103.78 KiB 322.21 KiB 90.23 KiB ███████▁▁▁▁▁
react-start.rsbuild.minimal 100.23 KiB -9 B (-0.01%) 100.06 KiB 316.76 KiB 86.39 KiB ▁▁▁▁▂▂▂█████
react-start.rsbuild.minimal-iife 100.63 KiB -10 B (-0.01%) 100.47 KiB 317.70 KiB 86.82 KiB ▁▁▁▁▂▂▂█████
react-start.rsbuild.full 103.56 KiB -12 B (-0.01%) 103.39 KiB 326.85 KiB 89.19 KiB ▁▁▁▁▃▃▃█████
solid-start.minimal 48.18 KiB -6 B (-0.01%) 48.05 KiB 142.08 KiB 42.81 KiB ███████▁▁▁▁▁
solid-start.deferred-hydration 51.44 KiB -7 B (-0.01%) 48.10 KiB 150.12 KiB 45.83 KiB ███████▁▁▁▁▁
solid-start.full 53.42 KiB -9 B (-0.02%) 53.29 KiB 157.82 KiB 47.33 KiB ████▆▆▆▁▁▁▁▁
vue-start.minimal 68.96 KiB -7 B (-0.01%) 68.84 KiB 195.09 KiB 61.46 KiB ████▆▆▆▁▁▁▁▁
vue-start.full 72.93 KiB -4 B (-0.01%) 72.80 KiB 207.60 KiB 64.78 KiB ████▆▆▆▁▁▁▁▁

Current gzip tracks all emitted client JS chunks. Initial gzip tracks only the entry/import graph. Trend sparkline is historical current gzip ending with this PR measurement; lower is better.

@pkg-pr-new

pkg-pr-new Bot commented Aug 6, 2026

Copy link
Copy Markdown
More templates

@tanstack/arktype-adapter

npm i https://pkg.pr.new/@tanstack/arktype-adapter@7978

@tanstack/eslint-plugin-router

npm i https://pkg.pr.new/@tanstack/eslint-plugin-router@7978

@tanstack/eslint-plugin-start

npm i https://pkg.pr.new/@tanstack/eslint-plugin-start@7978

@tanstack/history

npm i https://pkg.pr.new/@tanstack/history@7978

@tanstack/nitro-v2-vite-plugin

npm i https://pkg.pr.new/@tanstack/nitro-v2-vite-plugin@7978

@tanstack/react-router

npm i https://pkg.pr.new/@tanstack/react-router@7978

@tanstack/react-router-devtools

npm i https://pkg.pr.new/@tanstack/react-router-devtools@7978

@tanstack/react-router-ssr-query

npm i https://pkg.pr.new/@tanstack/react-router-ssr-query@7978

@tanstack/react-start

npm i https://pkg.pr.new/@tanstack/react-start@7978

@tanstack/react-start-client

npm i https://pkg.pr.new/@tanstack/react-start-client@7978

@tanstack/react-start-rsc

npm i https://pkg.pr.new/@tanstack/react-start-rsc@7978

@tanstack/react-start-server

npm i https://pkg.pr.new/@tanstack/react-start-server@7978

@tanstack/router-cli

npm i https://pkg.pr.new/@tanstack/router-cli@7978

@tanstack/router-core

npm i https://pkg.pr.new/@tanstack/router-core@7978

@tanstack/router-devtools

npm i https://pkg.pr.new/@tanstack/router-devtools@7978

@tanstack/router-devtools-core

npm i https://pkg.pr.new/@tanstack/router-devtools-core@7978

@tanstack/router-generator

npm i https://pkg.pr.new/@tanstack/router-generator@7978

@tanstack/router-plugin

npm i https://pkg.pr.new/@tanstack/router-plugin@7978

@tanstack/router-ssr-query-core

npm i https://pkg.pr.new/@tanstack/router-ssr-query-core@7978

@tanstack/router-utils

npm i https://pkg.pr.new/@tanstack/router-utils@7978

@tanstack/router-vite-plugin

npm i https://pkg.pr.new/@tanstack/router-vite-plugin@7978

@tanstack/solid-router

npm i https://pkg.pr.new/@tanstack/solid-router@7978

@tanstack/solid-router-devtools

npm i https://pkg.pr.new/@tanstack/solid-router-devtools@7978

@tanstack/solid-router-ssr-query

npm i https://pkg.pr.new/@tanstack/solid-router-ssr-query@7978

@tanstack/solid-start

npm i https://pkg.pr.new/@tanstack/solid-start@7978

@tanstack/solid-start-client

npm i https://pkg.pr.new/@tanstack/solid-start-client@7978

@tanstack/solid-start-server

npm i https://pkg.pr.new/@tanstack/solid-start-server@7978

@tanstack/start-client-core

npm i https://pkg.pr.new/@tanstack/start-client-core@7978

@tanstack/start-fn-stubs

npm i https://pkg.pr.new/@tanstack/start-fn-stubs@7978

@tanstack/start-plugin-core

npm i https://pkg.pr.new/@tanstack/start-plugin-core@7978

@tanstack/start-server-core

npm i https://pkg.pr.new/@tanstack/start-server-core@7978

@tanstack/start-static-server-functions

npm i https://pkg.pr.new/@tanstack/start-static-server-functions@7978

@tanstack/start-storage-context

npm i https://pkg.pr.new/@tanstack/start-storage-context@7978

@tanstack/valibot-adapter

npm i https://pkg.pr.new/@tanstack/valibot-adapter@7978

@tanstack/virtual-file-routes

npm i https://pkg.pr.new/@tanstack/virtual-file-routes@7978

@tanstack/vue-router

npm i https://pkg.pr.new/@tanstack/vue-router@7978

@tanstack/vue-router-devtools

npm i https://pkg.pr.new/@tanstack/vue-router-devtools@7978

@tanstack/vue-router-ssr-query

npm i https://pkg.pr.new/@tanstack/vue-router-ssr-query@7978

@tanstack/vue-start

npm i https://pkg.pr.new/@tanstack/vue-start@7978

@tanstack/vue-start-client

npm i https://pkg.pr.new/@tanstack/vue-start-client@7978

@tanstack/vue-start-server

npm i https://pkg.pr.new/@tanstack/vue-start-server@7978

@tanstack/zod-adapter

npm i https://pkg.pr.new/@tanstack/zod-adapter@7978

commit: b0c4ab1

@codspeed-hq

codspeed-hq Bot commented Aug 6, 2026

Copy link
Copy Markdown

Merging this PR will regress 4 benchmarks

⚠️ Different runtime environments detected

Some benchmarks with significant performance changes were compared across different runtime environments,
which may affect the accuracy of the results.

Open the report in CodSpeed to investigate

⚡ 8 improved benchmarks
❌ 4 regressed benchmarks
✅ 168 untouched benchmarks

Warning

Please fix the performance issues or acknowledge them on CodSpeed.

Performance Changes

Mode Benchmark BASE HEAD Efficiency
Memory mem server server-fn-churn (solid) 269.8 KB 3,683.3 KB -92.68%
Memory mem server error-paths not-found (solid) 415.1 KB 784.7 KB -47.1%
Simulation ssr server-fn during document ssr (react) 62.9 ms 66.2 ms -5.05%
Memory mem server error-paths not-found (react) 277.7 KB 286.9 KB -3.23%
Memory mem server server-fn-churn (vue) 4,147.3 KB 275.8 KB ×15
Memory mem server error-paths unmatched (vue) 2,142.1 KB 479 KB ×4.5
Memory mem server peak-large-page (react) 1,737.5 KB 952.1 KB +82.49%
Memory mem server error-paths redirect (solid) 388 KB 283.5 KB +36.87%
Memory mem server error-paths redirect (vue) 338.6 KB 294.7 KB +14.89%
Memory mem server error-paths unmatched (react) 317.5 KB 296 KB +7.27%
Memory mem client navigation-churn (vue) 1.3 MB 1.2 MB +3.62%
Memory mem client navigation-churn (solid) 580.3 KB 560.9 KB +3.44%

Tip

Investigate this regression by commenting @codspeedbot fix this regression on this PR, or directly use the CodSpeed MCP with your agent.


Comparing codex/frame-decoder-compact-result (b0c4ab1) with main (697ebb6)

Open in CodSpeed

@nx-cloud nx-cloud 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.

Important

At least one additional CI pipeline execution has run since the conclusion below was written and it may no longer be applicable.

Nx Cloud has identified a possible root cause for your failed CI:

We classified this failure as an environment issue rather than a code change. The test failed with EADDRINUSE on port 32915, meaning another process had already claimed that port before the test's external server could start — unrelated to the PR's internal key renames in @tanstack/start-client-core. No port configuration or test infrastructure was modified by this PR.

No code changes were suggested for this issue.

Trigger a rerun:

Rerun CI

Nx Cloud View detailed reasoning on Nx Cloud ↗


🎓 Learn more about Self-Healing CI on nx.dev

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant