perf: skip unused Start server routing work - #8444
schiller-manuel wants to merge 2 commits into
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (19)
Included review availability: Your plan provides up to 10 included reviews per hour; 8 remain after this review. 📝 WalkthroughWalkthroughChangesServer route detection and manifest propagation
Priority: ➖ Normal Estimated code review effort: 4 (Complex) | ~45 minutes Change: Refactor Sequence Diagram(s)sequenceDiagram
participant RoutePlugin
participant ManifestModule
participant createStartHandler
participant Router
RoutePlugin->>ManifestModule: generate routes and hasServerRoutes
ManifestModule->>createStartHandler: expose manifest metadata
createStartHandler->>Router: executeRouter or handleServerRoutes
Router-->>createStartHandler: return request response
Merge Risk: ⚪ Minimal · up to The routing optimization retains conservative fallbacks when metadata is unavailable and preserves server-function CSRF protection. No merge-blocking risk is identified. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 17.24% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 29 functions across 17 files. (2 skipped: 2 unsupported.) ✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
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. Comment |
|
View your CI Pipeline Execution ↗ for commit a1fbcb0
☁️ Nx Cloud last updated this comment at |
Bundle Size BenchmarksThis pull request does not affect bundle size in any measured scenario. |
🚀 Changeset Version Preview6 package(s) bumped directly, 17 bumped as dependents. 🟩 Patch bumps
|
Merging this PR will regress 1 benchmark
Warning Please fix the performance issues or acknowledge them on CodSpeed. Performance Changes
Tip Investigate this regression by commenting Comparing |
There was a problem hiding this comment.
Nx Cloud has identified a flaky task in your failed CI:
🔂 Since the failure was identified as flaky, we triggered a CI rerun by adding an empty commit to this branch.
🎓 Learn more about Self-Healing CI on nx.dev
🎯 Changes
Stacked on #8441.
Apps without a
serveroption on any route can skip server-route handling. Detect this during the existing Start build passes and emit a boolean in the server manifest. A single shared Start plugin handles the route metadata and compiler hooks.Also skip the request middleware chain when none are configured, cache entry imports in one function, and reuse the local router instance when early hints need route matching.
Validation: affected unit, type, and lint checks passed; 46 Chromium cases passed across server routes, early hints, dev SSR styles, and custom Rsbuild servers. The standard Rsbuild production build also passed.
✅ Checklist
🚀 Release Impact
Summary by CodeRabbit
Performance Improvements
Bug Fixes
Tests