Skip to content

feat(server): publish rebuilt SSR application resources - #8862

Merged
2heal1 merged 1 commit into
feat/mf-ssr-clear-cachefrom
feat/ssr-application-generation
Sep 11, 2026
Merged

2heal1 merged 1 commit into
feat/mf-ssr-clear-cachefrom
feat/ssr-application-generation

Conversation

@2heal1

@2heal1 2heal1 commented Sep 10, 2026

Copy link
Copy Markdown
Member

Summary

Add opt-in createProdServer({ ssrApplication }) integration for same-process SSR application publication. Admission now precedes direct/plugin middleware and resource selection. Updates drain requests and producer work, run the owned invalidator/disposer, reload declared CommonJS render/loader roots, validate fresh resources and publish a new renderer and HTML-cache namespace. Failed preparation cleans candidate adapters and keeps SSR unavailable until an explicit retry; the HTTP server and logical MF control plane remain.

Also propagate work into standalone data loaders and settle their deferred response subscriptions on cancellation, abort and serialization failure. Static/liveness bypass is an explicit direct-response hook; unconfigured routes remain behind the application-wide gate. Native ESM application roots are rejected. RSC is excluded.

The real production test found a shared-factory identity bug in both MF cleanup layers. Use with companion module-federation/core #5053. With that repair, compiled dynamic remotes v1/v2/v3 pass on one PID/port with queued requests using new handlers, strict host/provider shared identity, adapter detachment, preserved business globals and failed-warmup recovery. The test compiles before serving; updates do not rerun serve or compile the host.

Validation: server-core 46/46; data-loader 10 passed plus one pre-existing skipped test; three affected package builds/declarations; native HTTP artifact tests 3/3; production MF artifact 1/1; prior strict local Rspack/Modern baseline 13/13; Biome, Changesets and commit hooks pass. The companion MF suites pass 138/138 and 122/122. Its full Prettier gate reports 683 existing/generated or unrelated dirty files; touched files pass. Full framework/builder/browser-hydration, Cypress and load/heap endurance are not claimed complete and remain RFC R6. Exact commands and limitations: packages/server/core/SSR_REQUEST_COORDINATION.md.

This is R3's application rebuild path. R4 selective planning and R5 final MF update API/migration are still pending; no release is performed.

Related Links

Checklist

  • I have added changeset via pnpm run change.
  • I have updated the documentation.
  • I have added tests to cover my changes.

@github-actions

Copy link
Copy Markdown
Contributor

Rsdoctor Bundle Diff Analysis

⚠️ Note: The latest commit (4af5bf05b6) does not have baseline artifacts. Using commit 2e6d853724 for baseline comparison instead. If this seems incorrect, please wait a few minutes and try rerunning the workflow.

📊 Quick Summary
Project Total Size Change
bundle-diff 473.2 KB +642.0 B (0.1%)
📋 Detailed Reports (Click to expand)

📁 bundle-diff

Path: benchmark/bundle-diff/dist/rsdoctor-data.json

📌 Baseline Commit: 2e6d853724 | PR: #8859

Metric Current Baseline Change
📊 Total Size 473.2 KB 472.6 KB +642.0 B (0.1%)
📄 JavaScript 465.8 KB 465.1 KB +642.0 B (0.1%)
🎨 CSS 1.2 KB 1.2 KB 0
🌐 HTML 5.5 KB 5.5 KB 0
📁 Other Assets 765.0 B 765.0 B 0

📦 Download Diff Report: bundle-diff Bundle Diff

Generated by Rsdoctor GitHub Action

@2heal1
2heal1 merged commit da04be9 into feat/mf-ssr-clear-cache Sep 11, 2026
1 check passed
@2heal1
2heal1 deleted the feat/ssr-application-generation branch September 11, 2026 02:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant