Skip to content

feat: Add BullMQ attributes and metrics - #690

Open
JPeer264 wants to merge 1 commit into
mainfrom
jp/bullmq-attributes
Open

JPeer264 wants to merge 1 commit into
mainfrom
jp/bullmq-attributes

Conversation

@JPeer264

@JPeer264 JPeer264 commented Oct 9, 2026 •

Copy link
Copy Markdown
Member

Description

This registers the attributes and metrics that the BullMQ integration of the JavaScript SDK sends (getsentry/sentry-javascript#21777). BullMQ sets them itself through its telemetry interface, and the SDK forwards them. The metrics are opt_in, because the SDK sends them only with enableMetrics: true.

Naming decisions

The keys are the exact names BullMQ emits, also multi-word names with dots such as bullmq.worker.do.not.wait.active. The five BullMQ attributes that have a messaging.* equivalent are not registered, because the SDK replaces them.

Scrubbing decisions

apply_scrubbing is auto for values from user code (bullmq.job.progress, bullmq.job.deduplication.key, bullmq.job.key) and manual for all others.

Known issues

  • bullmq.job.status (BullMQ 5) and bullmq.job.state (BullMQ 6) are the same metric attribute, renamed by BullMQ.

PR Checklist

  • I have run yarn test and verified that the tests pass.
  • I have run yarn generate to generate and format code and docs.

If an attribute was added:

  • The attribute is in a namespace (e.g. nextjs.function_id, not function_id)
  • I have used the correct value for apply_scrubbing (i.e. manual or auto. Use never only for values that should never be scrubbed such as IDs)

@vercel

vercel Bot commented Oct 9, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
sentry-conventions Ready Ready Preview Oct 9, 2026 9:30am UTC

Request Review

@github-actions

github-actions Bot commented Oct 9, 2026 •

Copy link
Copy Markdown

Semver Impact of This PR

🟡 Minor (new features)

📋 Changelog Preview

This is how your changes will appear in the changelog.
Entries from this PR are highlighted with a left border (blockquote style).


New Features ✨

Attributes

  • Add integrity policy attributes by loewenheim in #691
  • Deprecate legacy MCP tool result fields by betegon in #689
  • Align MCP conventions and OAuth client identity by betegon in #671
  • Add AWS service instrumentation attributes by pabloDeputter in #672
  • Add gen_ai memory conventions by ArthurKnaus in #653

Other

  • (model) Add metric model by giortzisg in #649
  • Add BullMQ attributes and metrics by JPeer264 in #690
  • Add enum_values entries to shorten attribute briefs by alexander-alderman-webb in #685

Bug Fixes 🐛

Attributes

  • Add search_alias to sentry.link.type attribute by Lms24 in #687
  • Remove any as valid attribute type by Lms24 in #677

Documentation 📚

  • (contributing) Document process for fixing a misnamed attribute by sentry-junior in #673

Internal Changes 🔧

Deps

  • Bump sharp from 0.35.4 to 0.35.5 by dependabot in #683
  • Bump source-map-js from 1.2.1 to 1.2.2 by dependabot in #675
  • Bump smol-toml from 1.8.0 to 1.9.0 by dependabot in #674
  • Bump postcss-selector-parser from 7.1.4 to 7.1.6 by dependabot in #676

Other

  • (deps-dev) Bump oxfmt to 0.72.0 to pull in patched tinypool by Lms24 in #682
  • (docs) Add link preview meta tags by Lms24 in #667
  • (publish) Stop npm version from rewriting yarn.lock by Lms24 in #678
  • Add "evaluate" as a well-known value for gen_ai.operation.name by alexander-alderman-webb in #680
  • Deprecate mcp.tool.result.content_count by alexander-alderman-webb in #669

🤖 This preview updates automatically when you update the PR.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@JPeer264
JPeer264 force-pushed the jp/bullmq-attributes branch from b2de364 to fc9eb9d Compare October 9, 2026 09:30
@JPeer264 JPeer264 changed the title feat(attributes): Add BullMQ attributes feat: Add BullMQ attributes and metrics Oct 9, 2026
@JPeer264
JPeer264 marked this pull request as ready for review October 9, 2026 10:20
/**
* Type for {@link BULLMQ_FLOW_NAME} bullmq.flow.name
*/
export type BULLMQ_FLOW_NAME_TYPE = string;

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.

I thought it was preferred to use the existing messaging.* attributes?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Yeah we do for these values: https://github.com/getsentry/sentry-javascript/pull/21777/changes#diff-b231e1ca3c1e7c4c3f1f1deba1efd6a0d0f272621d92e62bbf1a4a0f51756213R22-R26

bullmq.flow.name would kinda be a messaging name, but we don't have an exact equivalent.

This branch was successfully deployed

1 active deployment
Preview — fc9eb9d0 Deployed Oct 9, 2026 by vercel[bot]
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.

3 participants