Skip to content

docs(dotnet/logs): add log4net structured logs integration#18739

Open
jamescrosswell wants to merge 2 commits into
masterfrom
dotnet-log4net-logs-docs
Open

docs(dotnet/logs): add log4net structured logs integration#18739
jamescrosswell wants to merge 2 commits into
masterfrom
dotnet-log4net-logs-docs

Conversation

@jamescrosswell

Copy link
Copy Markdown
Collaborator

DESCRIBE YOUR PR

Documents the new log4net structured logs integration added in getsentry/sentry-dotnet#5172, mirroring the existing Serilog logs documentation and the sibling NLog logs docs PR (#18738).

Changes

  • Enable the Logs page for the log4net guide — removed dotnet.log4net from the notSupported list in common/logs/index.mdx, so /platforms/dotnet/guides/log4net/logs/ now renders.
  • log4net guide (guides/log4net/index.mdx) — added a cross-link to the Logs page.
  • Product Logs getting-started — added log4net to the list of supported SDKs.
  • logs/* platform-includes (requirements, setup, usage, options, integrations) — added log4net-specific content: enabling EnableLogs via SentrySdk.Init (log4net's appender doesn't expose it), the log4net→Sentry level mapping, and the category.name/property.<name> attribute behavior.

⚠️ Needs confirmation

The version in requirements/dotnet.mdx is a placeholder — 6.8.0. The source PR (getsentry/sentry-dotnet#5172) isn't released yet (current released version is 6.6.0), so please correct this to whatever release actually ships the Sentry.Log4Net structured-logs feature.

Notes

  • Faithful port of the Serilog/NLog logs docs onto log4net — same structure, PlatformSection gating, and phrasing.
  • log4net-specific caveat documented: because log4net renders messages before they reach the appender, its structured logs carry the formatted message but no template or parameters (unlike Serilog/NLog).
  • Should merge only once/after feat(logs): add log4net integration sentry-dotnet#5172 lands and its release version is known.

Related: getsentry/sentry-dotnet#5172

IS YOUR CHANGE URGENT?

Help us prioritize incoming PRs by letting us know when the change needs to go live.

  • Urgent deadline (GA date, etc.):
  • Other deadline:
  • None: Not urgent, can wait up to 1 week+

SLA

  • Teamwork makes the dream work, so please add a reviewer to your PRs.
  • Please give the docs team up to 1 week to review your PR unless you've added an urgent due date to it.
    Thanks in advance for your help!

PRE-MERGE CHECKLIST

Make sure you've checked the following before merging your changes:

  • 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

🤖 Generated with Claude Code

Documents the new log4net structured logs integration added in
getsentry/sentry-dotnet#5172, mirroring the existing Serilog/NLog logs docs.

- Enable the Logs page for the log4net guide (remove dotnet.log4net from
  the notSupported list in common/logs/index.mdx).
- log4net guide: cross-link to the Logs page.
- Product Logs getting-started: add log4net to the supported SDK list.
- logs/* platform-includes (requirements, setup, usage, options,
  integrations): add log4net-specific content — EnableLogs via SentrySdk.Init,
  the log4net level mapping, and the category.name/property attribute behavior.

Co-Authored-By: Claude Opus 4.8 <[email protected]>
@vercel

vercel Bot commented Jul 16, 2026

Copy link
Copy Markdown

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

Project Deployment Actions Updated (UTC)
sentry-docs Ready Ready Preview Jul 16, 2026 3:43am
1 Skipped Deployment
Project Deployment Actions Updated (UTC)
develop-docs Ignored Ignored Preview Jul 16, 2026 3:43am

Request Review

… logs

The SentryAppender's Environment and SendIdentity settings now apply to
structured logs as well as events (getsentry/sentry-dotnet#5172).

Co-Authored-By: Claude Opus 4.8 <[email protected]>
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