Skip to content

feat(observability): add runtime diagnostics and Divebell sync - #4813

Open
2heal1 wants to merge 33 commits into
mainfrom
feat/operate-openruntime
Open

feat(observability): add runtime diagnostics and Divebell sync#4813
2heal1 wants to merge 33 commits into
mainfrom
feat/operate-openruntime

Conversation

@2heal1

@2heal1 2heal1 commented Jun 14, 2026

Copy link
Copy Markdown
Member

Description

This PR adds Module Federation runtime observability for remote resources, shared dependencies, Bridge lifecycles, runtime errors, and multi-instance state. It keeps the runtime changes focused on semantic hooks while the observability plugin owns report collection, diagnosis, correlation, and browser inspection.

The observability plugin now syncs remote, exposed-module, and shared-dependency state to Divebell through @divebell/core@0.0.3. The integration follows the current Divebell API, including the removal of input-option providers. The runtime demo, automated coverage, documentation, and changesets have been updated accordingly.

Validation completed:

  • pnpm --filter @module-federation/observability-plugin run build
  • pnpm --filter @module-federation/observability-plugin run test — 111 tests passed
  • pnpm --filter @module-federation/playground run build
  • pnpm run ci:local --only=e2e-runtime — 28 browser tests passed
  • pnpm --filter @module-federation/observability-plugin run lint
  • pnpm exec prettier --check .
  • Changeset release-plan validation passed

Broader unrelated CI jobs were not rerun for the dependency-only follow-up because the affected packages and runtime demo already have targeted coverage.

Related Issue

No related issue was provided.

Types of changes

  • Docs change / refactoring / dependency upgrade
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)

Checklist

  • I have added tests to cover my changes.
  • All new and existing tests passed.
  • I have updated the documentation.

@changeset-bot

changeset-bot Bot commented Jun 14, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 3620cd5

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 48 packages
Name Type
@module-federation/runtime-core Major
@module-federation/runtime Major
@module-federation/bridge-shared Major
@module-federation/bridge-react Major
@module-federation/bridge-vue3 Major
@module-federation/observability-plugin Minor
@module-federation/webpack-bundler-runtime Major
@module-federation/playground Minor
@module-federation/nextjs-mf Patch
@module-federation/devtools Major
@module-federation/dts-plugin Major
@module-federation/esbuild Patch
@module-federation/metro Major
@module-federation/modern-js-v3 Major
@module-federation/modern-js Major
@module-federation/node Patch
@module-federation/retry-plugin Major
@module-federation/runtime-tools Major
website-new Patch
remote5 Patch
remote6 Patch
@module-federation/enhanced Major
@module-federation/metro-plugin-rnc-cli Major
@module-federation/metro-plugin-rnef Major
@module-federation/metro-plugin-rock Major
shared-tree-shaking-with-server-host Patch
shared-tree-shaking-with-server-provider Patch
@module-federation/rsbuild-plugin Major
@module-federation/rstest Major
node-dynamic-remote-new-version Patch
node-dynamic-remote Patch
@module-federation/rspack Major
@module-federation/inject-external-runtime-core-plugin Major
@module-federation/rspress-plugin Major
@module-federation/storybook-addon Major
shared-tree-shaking-no-server-host Patch
shared-tree-shaking-no-server-provider Patch
@module-federation/sdk Major
@module-federation/managers Major
@module-federation/manifest Major
@module-federation/third-party-dts-extractor Major
@module-federation/bridge-react-webpack-plugin Major
@module-federation/error-codes Major
create-module-federation Major
@module-federation/cli Major
@module-federation/treeshake-server Major
@module-federation/treeshake-frontend Major
@module-federation/utilities Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@netlify

netlify Bot commented Jun 14, 2026

Copy link
Copy Markdown

Deploy Preview for module-federation-docs ready!

Name Link
🔨 Latest commit cfd28c9
🔍 Latest deploy log https://app.netlify.com/projects/module-federation-docs/deploys/6a3b8493b0724c00072f7bd0
😎 Deploy Preview https://deploy-preview-4813--module-federation-docs.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
🤖 Make changes Run an agent on this branch

To edit notification comments on pull requests, go to your Netlify project configuration.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 0236c49ce6

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

"dependencies": {
"@module-federation/sdk": "workspace:*"
"@module-federation/sdk": "workspace:*",
"@openruntime/core": "link:/Users/bytedance/ai/openruntime/packages/core"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Replace the absolute local OpenRuntime dependency

This new dependency points at /Users/bytedance/..., so a clean checkout or CI runner that does not have that developer-local path cannot satisfy pnpm install --frozen-lockfile, and a published @module-federation/observability-plugin would also carry an unusable local link. Since the new source imports @openruntime/core, this needs to be a real registry/workspace version rather than an absolute link: path.

Useful? React with 👍 / 👎.

@pkg-pr-new

pkg-pr-new Bot commented Jul 21, 2026

Copy link
Copy Markdown

Open in StackBlitz

@module-federation/devtools

pnpm add https://pkg.pr.new/@module-federation/devtools@3620cd5

@module-federation/cli

pnpm add https://pkg.pr.new/@module-federation/cli@3620cd5

create-module-federation

pnpm add https://pkg.pr.new/create-module-federation@3620cd5

@module-federation/dts-plugin

pnpm add https://pkg.pr.new/@module-federation/dts-plugin@3620cd5

@module-federation/enhanced

pnpm add https://pkg.pr.new/@module-federation/enhanced@3620cd5

@module-federation/error-codes

pnpm add https://pkg.pr.new/@module-federation/error-codes@3620cd5

@module-federation/esbuild

pnpm add https://pkg.pr.new/@module-federation/esbuild@3620cd5

@module-federation/managers

pnpm add https://pkg.pr.new/@module-federation/managers@3620cd5

@module-federation/manifest

pnpm add https://pkg.pr.new/@module-federation/manifest@3620cd5

@module-federation/metro

pnpm add https://pkg.pr.new/@module-federation/metro@3620cd5

@module-federation/metro-plugin-rnc-cli

pnpm add https://pkg.pr.new/@module-federation/metro-plugin-rnc-cli@3620cd5

@module-federation/metro-plugin-rnef

pnpm add https://pkg.pr.new/@module-federation/metro-plugin-rnef@3620cd5

@module-federation/metro-plugin-rock

pnpm add https://pkg.pr.new/@module-federation/metro-plugin-rock@3620cd5

@module-federation/modern-js

pnpm add https://pkg.pr.new/@module-federation/modern-js@3620cd5

@module-federation/modern-js-v3

pnpm add https://pkg.pr.new/@module-federation/modern-js-v3@3620cd5

@module-federation/native-federation-tests

pnpm add https://pkg.pr.new/@module-federation/native-federation-tests@3620cd5

@module-federation/native-federation-typescript

pnpm add https://pkg.pr.new/@module-federation/native-federation-typescript@3620cd5

@module-federation/nextjs-mf

pnpm add https://pkg.pr.new/@module-federation/nextjs-mf@3620cd5

@module-federation/node

pnpm add https://pkg.pr.new/@module-federation/node@3620cd5

@module-federation/observability-plugin

pnpm add https://pkg.pr.new/@module-federation/observability-plugin@3620cd5

@module-federation/playground

pnpm add https://pkg.pr.new/@module-federation/playground@3620cd5

@module-federation/retry-plugin

pnpm add https://pkg.pr.new/@module-federation/retry-plugin@3620cd5

@module-federation/rsbuild-plugin

pnpm add https://pkg.pr.new/@module-federation/rsbuild-plugin@3620cd5

@module-federation/rspack

pnpm add https://pkg.pr.new/@module-federation/rspack@3620cd5

@module-federation/rspress-plugin

pnpm add https://pkg.pr.new/@module-federation/rspress-plugin@3620cd5

@module-federation/rstest

pnpm add https://pkg.pr.new/@module-federation/rstest@3620cd5

@module-federation/runtime

pnpm add https://pkg.pr.new/@module-federation/runtime@3620cd5

@module-federation/runtime-core

pnpm add https://pkg.pr.new/@module-federation/runtime-core@3620cd5

@module-federation/runtime-tools

pnpm add https://pkg.pr.new/@module-federation/runtime-tools@3620cd5

@module-federation/sdk

pnpm add https://pkg.pr.new/@module-federation/sdk@3620cd5

@module-federation/storybook-addon

pnpm add https://pkg.pr.new/@module-federation/storybook-addon@3620cd5

@module-federation/third-party-dts-extractor

pnpm add https://pkg.pr.new/@module-federation/third-party-dts-extractor@3620cd5

@module-federation/treeshake-frontend

pnpm add https://pkg.pr.new/@module-federation/treeshake-frontend@3620cd5

@module-federation/treeshake-server

pnpm add https://pkg.pr.new/@module-federation/treeshake-server@3620cd5

@module-federation/typescript

pnpm add https://pkg.pr.new/@module-federation/typescript@3620cd5

@module-federation/utilities

pnpm add https://pkg.pr.new/@module-federation/utilities@3620cd5

@module-federation/webpack-bundler-runtime

pnpm add https://pkg.pr.new/@module-federation/webpack-bundler-runtime@3620cd5

@module-federation/bridge-react

pnpm add https://pkg.pr.new/@module-federation/bridge-react@3620cd5

@module-federation/bridge-react-webpack-plugin

pnpm add https://pkg.pr.new/@module-federation/bridge-react-webpack-plugin@3620cd5

@module-federation/bridge-shared

pnpm add https://pkg.pr.new/@module-federation/bridge-shared@3620cd5

@module-federation/bridge-vue3

pnpm add https://pkg.pr.new/@module-federation/bridge-vue3@3620cd5

@module-federation/inject-external-runtime-core-plugin

pnpm add https://pkg.pr.new/@module-federation/inject-external-runtime-core-plugin@3620cd5

commit: 3620cd5

@github-actions

github-actions Bot commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

🚀 Preview Environment Ready!

Name Status URL
website-new ✅ Active https://nestor-lopez-31404-website-new-core-module-federa-6b9464e... ↗

Details:

  • Latest Commit: 9de29ae
  • Updated at: 7/30/2026, 8:06:06 AM

@github-actions

github-actions Bot commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Bundle Size Report

16 package(s) changed, 27 unchanged.

Package dist + ESM entry

Package Total dist (raw) Delta ESM gzip Delta
@module-federation/bridge-react 308.4 kB +5.5 kB (+1.8%) 1.5 kB +193 B (+14.6%)
@module-federation/bridge-shared 1.9 kB +819 B (+75.7%) 137 B no change
@module-federation/bridge-vue3 191.5 kB +9.2 kB (+5.0%) 27.4 kB +942 B (+3.5%)
@module-federation/dts-plugin 335.2 kB +1.6 kB (+0.5%) 4.7 kB no change
@module-federation/observability-plugin 479.7 kB +197.6 kB (+70.0%) 150 B no change
@module-federation/playground 28.91 MB +32.9 kB (+0.1%) 45.6 kB +421 B (+0.9%)
@module-federation/runtime 20.4 kB +434 B (+2.1%) 724 B +9 B (+1.3%)
@module-federation/runtime-core 310.3 kB +10.8 kB (+3.6%) 570 B no change
@module-federation/runtime-tools 7.8 kB +65 B (+0.8%) 142 B no change
@module-federation/webpack-bundler-runtime 68.1 kB +408 B (+0.6%) 531 B no change

Bundle targets

Package Web bundle (gzip) Delta Node bundle (gzip) Delta
@module-federation/bridge-react 13.4 kB +232 B (+1.7%) 14.3 kB +236 B (+1.6%)
@module-federation/bridge-vue3 20.0 kB +530 B (+2.7%) 20.1 kB +498 B (+2.5%)
@module-federation/cli 2.3 kB -9 B (-0.4%) 2.4 kB -32 B (-1.3%)
@module-federation/core 1.0 kB -3 B (-0.3%) 1.0 kB -33 B (-3.0%)
@module-federation/devtools 30.3 kB -10 B (-0.0%) 30.3 kB -35 B (-0.1%)
@module-federation/enhanced 2.7 kB +4 B (+0.1%) 2.8 kB -43 B (-1.5%)
@module-federation/metro-plugin-rnc-cli 416 B no change 435 B -25 B (-5.4%)
@module-federation/node 9.1 kB +3 B (+0.0%) 9.2 kB -28 B (-0.3%)
@module-federation/observability-plugin 24.5 kB +12.3 kB (+100.8%) 24.5 kB +12.3 kB (+100.8%)
@module-federation/playground 41.5 kB +427 B (+1.0%) 41.5 kB +427 B (+1.0%)
@module-federation/runtime 697 B +12 B (+1.8%) 697 B +12 B (+1.8%)
@module-federation/runtime-core 16.1 kB +511 B (+3.2%) 15.8 kB +510 B (+3.3%)
@module-federation/webpack-bundler-runtime 4.1 kB +26 B (+0.6%) 4.1 kB +26 B (+0.6%)

Tree-shakable entrypoints

Package Export Entry gzip Delta Web bundle (gzip) Delta Node bundle (gzip) Delta Gap (node-web) Delta
@module-federation/runtime ./bundler 184 B +7 B (+4.0%) 697 B +12 B (+1.8%) 697 B +12 B (+1.8%) 0 B 0 B
@module-federation/webpack-bundler-runtime ./bundler 151 B no change 4.1 kB +26 B (+0.6%) 4.1 kB +26 B (+0.6%) 0 B 0 B

Consumer scenarios

Scenario Web output (gzip) Delta Node output (gzip) Delta Gap (node-web) Delta
Enhanced remoteEntry 22.2 kB +484 B (+2.2%) 23.8 kB +482 B (+2.0%) +1.6 kB -2 B

Total dist (raw): 36.16 MB (+259.2 kB (+0.7%))
Total ESM gzip: 111.4 kB (+1.5 kB (+1.4%))
Total web bundle (gzip): 253.0 kB (+14.0 kB (+5.9%))
Total node bundle (gzip): 255.2 kB (+13.8 kB (+5.7%))
Tracked ./bundler entry gzip: 563 B (+7 B (+1.3%))
Tracked ./bundler web bundle (gzip): 4.9 kB (+38 B (+0.8%))
Tracked ./bundler node bundle (gzip): 4.9 kB (+38 B (+0.8%))

Bundle sizes are generated with rslib (Rspack). Package-root metrics preserve the historical report. Tracked subpath exports such as ./bundler are measured separately so ENV_TARGET-driven tree-shaking is visible. Bare imports are externalized to keep package-level sizes consistent, and assets are emitted as resources.

@2heal1
2heal1 force-pushed the feat/operate-openruntime branch from e80ae52 to 8608846 Compare July 28, 2026 06:52
@2heal1 2heal1 changed the title feat: sync MF observability to OpenRuntime feat(observability): add runtime diagnostics and Divebell sync Jul 29, 2026
@2heal1
2heal1 force-pushed the feat/operate-openruntime branch 2 times, most recently from 6385b09 to 23dfed1 Compare August 13, 2026 06:21
@2heal1
2heal1 force-pushed the feat/operate-openruntime branch from 23dfed1 to 7baff59 Compare August 17, 2026 06:14
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