Skip to content

docs(nestjs): Document SentryCron monitor config from @Cron - #19782

Open
wedamija wants to merge 5 commits into
masterfrom
danf/nestjs-cron-config
Open

wedamija wants to merge 5 commits into
masterfrom
danf/nestjs-cron-config

Conversation

@wedamija

@wedamija wedamija commented Oct 2, 2026 •

Copy link
Copy Markdown
Member

DESCRIBE YOUR PR

Documents that @SentryCron now sends the schedule and time zone of @Cron on the same method, so check-ins create the monitor. Covers the server time zone default, which schedules send no config, and the fromCronDecorator: false opt-out.

SDK change: getsentry/sentry-javascript#25013. Merge after it ships; the page marks it as available since 11.5.0, which assumes it lands in the next minor.

IS YOUR CHANGE URGENT?

  • Urgent deadline (GA date, etc.): YYYY-MM-DD
  • Other deadline: YYYY-MM-DD
  • No deadline: Not urgent, can wait up to 1 week+

PRE-MERGE CHECKLIST

  • Checked Vercel preview for correctness, including links
  • PR was reviewed and approved by any necessary SMEs (subject matter experts)
  • PR was reviewed and approved by a member of the Sentry docs team

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@vercel

vercel Bot commented Oct 2, 2026 •

Copy link
Copy Markdown

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

Project Deployment Actions Updated
sentry-docs Ready Ready Preview Oct 2, 2026 10:11pm UTC
1 Skipped Deployment
Project Deployment Actions Updated
develop-docs Ignored Ignored Preview Oct 2, 2026 10:11pm UTC

Request Review

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
@wedamija
wedamija requested a review from a team October 2, 2026 22:29
@wedamija
wedamija marked this pull request as ready for review October 2, 2026 22:29
@cursor

cursor Bot commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

The plan checks errors on the changed guide pages, loads of those pages, and site error volume. An issue escalates when those page errors appear or site errors rise.

Services: sentry-docs.

Mention @change-monitor in a comment to update the plan.

Plan

What changed

The NestJS Cron decorator docs now describe auto monitor config from @Cron. Readers who omit a schedule see that check-ins send the Cron schedule and time zone. The sentry-docs service must deploy before this section is live. The text is marked available since 11.5.0.

Risk

Wrong MDX can fail both pages that share this include. A broken code block can fail the shared code tab on those pages. Readers can then miss how to create a monitor from @Cron.

Intended effect

This change is a docs edit. No queryable signal shows the new section is live. absent is the normal telemetry state. Do not treat a zero counter as failure.

Regression watch

This include ships on the NestJS Cron decorator page and the NestJS crons setup page. A render fault would show as errors or a drop in NestJS guide loads.

Signal Baseline Window Rule Source
NestJS guide page errors 0 events. Error rate 0% against 123 guide loads 2026-10-01T22:30:00Z to 2026-10-02T22:30:00Z Hold at 0 Sentry project docs. Production errors whose transaction or url contains nestjs
Docs production errors 0-22 events per hour. 154 events in 24h 2026-10-01T22:30:00Z to 2026-10-02T22:30:00Z Hold in the 0-22 per hour band Sentry project docs. environment:production error count
NestJS guide pageload and navigation 123 spans. p95 24.6s 2026-10-01T22:30:00Z to 2026-10-02T22:30:00Z Volume should stay near 123 per 24h. p95 should stay near 24.6s Sentry project docs. pageload or navigation spans whose url contains javascript/guides/nestjs

The 24h p95 may include slow navigations. Escalate when NestJS guide errors leave zero or site errors leave the hourly band.

Not observable

Whether the new heading is visible on the published pages. Traffic on the sentry-cron-decorator page alone had no traces in this window. Whether the JavaScript SDK ships the 11.5.0 Cron behavior.

Comment on lines +50 to +56
```

If `@Cron` has no `timeZone`, the job runs in your server's local time zone, so that time zone is sent.

A six-field expression is sent without its seconds field if that field is a single number, such as `0 30 9 * * *`. Presets such as `@daily` and `@weekly` are sent too. Sub-minute schedules, `Date` values, `utcOffset`, numeric months (use names such as `MAY`), a `*/n` day field combined with the other day field, and time zones that aren't IANA names send no monitor config, including any other options you pass. In those cases, pass a full monitor config to `@SentryCron` or create the monitor in Sentry first.

To send check-ins without a monitor config, pass `{ fromCronDecorator: false }`.

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.

Bug: The documentation for fromCronDecorator: false is for an unreleased SDK feature and may become incorrect if the final implementation uses a different name.
Severity: MEDIUM

Suggested Fix

Confirm the final property name from the corresponding SDK implementation (sentry-javascript PR #25013) once it has been released. It is recommended to merge this documentation change only after the SDK feature is shipped to ensure accuracy.

Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent. Verify if this is a real issue. If it is, propose a fix; if not, explain why it's
not valid.

Location: includes/nestjs-sentry-cron-decorator.mdx#L50-L56

Potential issue: The documentation introduces the `fromCronDecorator: false` option,
which is tied to an unreleased SDK feature (version 11.5.0). The pull request notes that
this documentation should only be merged after the SDK feature ships. Because the
feature is not yet released, the final property name in the SDK might differ. If the
name changes, the documentation will be incorrect, and users attempting to use
`fromCronDecorator: false` will find that it has no effect, causing confusion.

Did we get this right? 👍 / 👎 to inform future reviews.

This branch was successfully deployed

1 active deployment
Preview – sentry-docs — d33c58d5 Deployed Oct 2, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Priority: Normal Docs review has no urgent deadline

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant