Skip to content

feat: add span for composeGraphsInWorker - #2901

Merged
wilsonrivera merged 3 commits into
mainfrom
wilson/eng-9671-controlplane-add-span-for-composegraphsinworker
May 29, 2026
Merged

feat: add span for composeGraphsInWorker#2901
wilsonrivera merged 3 commits into
mainfrom
wilson/eng-9671-controlplane-add-span-for-composegraphsinworker

Conversation

@wilsonrivera

@wilsonrivera wilsonrivera commented May 29, 2026

Copy link
Copy Markdown
Contributor

Summary by CodeRabbit

  • Chores
    • Enhanced monitoring and diagnostics for graph composition operations to improve system reliability and error detection.

Review Change Stack

Checklist

Open Source AI Manifesto

This project follows the principles of the Open Source AI Manifesto. Please ensure your contribution aligns with its principles.

@coderabbitai

coderabbitai Bot commented May 29, 2026

Copy link
Copy Markdown
Contributor

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: c93d8f22-a101-423b-8161-d86e003cc5d9

📥 Commits

Reviewing files that changed from the base of the PR and between 2c2cb71 and 2ea3539.

📒 Files selected for processing (1)
  • controlplane/src/core/composition/composeGraphs.pool.ts

Walkthrough

This PR adds Sentry observability instrumentation to the composeGraphsInWorker function. The change imports @sentry/node and wraps the worker pool task execution in a Sentry.startSpan with span name and attributes derived from the federated graph. The function now explicitly declares its return type as Promise<ComposeGraphsTaskResult>.

Changes

Sentry observability instrumentation

Layer / File(s) Summary
Sentry span instrumentation for graph composition
controlplane/src/core/composition/composeGraphs.pool.ts
Added @sentry/node import and refactored composeGraphsInWorker to wrap worker pool execution in Sentry.startSpan, attaching span attributes (id, name, subgraphsCount, organizationId, namespaceId) from the federated graph and explicitly declaring the return type Promise<ComposeGraphsTaskResult>.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately describes the main change: adding Sentry span instrumentation to the composeGraphsInWorker function.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch

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

@wilsonrivera
wilsonrivera marked this pull request as ready for review May 29, 2026 20:55
@wilsonrivera
wilsonrivera requested a review from a team as a code owner May 29, 2026 20:55

@claude claude 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.

Claude Code Review

This repository is configured for manual code reviews. Comment @claude review to trigger a review and subscribe this PR to future pushes, or @claude review once for a one-time review.

Tip: disable this comment in your organization's Code Review settings.

@Aenimus Aenimus left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM!

@codecov

codecov Bot commented May 29, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 64.61%. Comparing base (c395857) to head (f1d7f82).

Additional details and impacted files
@@             Coverage Diff             @@
##             main    #2901       +/-   ##
===========================================
+ Coverage   33.51%   64.61%   +31.10%     
===========================================
  Files         648      326      -322     
  Lines       91845    46629    -45216     
  Branches     5602     5145      -457     
===========================================
- Hits        30781    30131      -650     
+ Misses      60728    16473    -44255     
+ Partials      336       25      -311     
Files with missing lines Coverage Δ
...olplane/src/core/composition/composeGraphs.pool.ts 84.31% <100.00%> (+2.49%) ⬆️

... and 322 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@wilsonrivera
wilsonrivera merged commit 254810f into main May 29, 2026
12 checks passed
@wilsonrivera
wilsonrivera deleted the wilson/eng-9671-controlplane-add-span-for-composegraphsinworker branch May 29, 2026 21:29
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.

2 participants