Skip to content

Commit 1a438ff

Browse files
committed
ref(logs): Change documentation for logs sentry.origin consolidation
1 parent 33c8c77 commit 1a438ff

File tree

2 files changed

+14
-6
lines changed

2 files changed

+14
-6
lines changed

develop-docs/sdk/telemetry/logs.mdx

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -305,13 +305,20 @@ If there are no `sentry.message.parameter.X` attributes included in the log, the
305305

306306
#### SDK Integration Attributes
307307

308-
If a log is generated by an SDK integration, the SDK should also set the `sentry.origin` attribute, as per the [Trace Origin](/sdk/telemetry/traces/trace-origin/) documentation. It is assumed that logs without a `sentry.origin` attribute are manually created by the user.
308+
If a log is generated by an SDK integration, the SDK should also set the `sentry.origin` attribute, as per the [Trace Origin](/sdk/telemetry/traces/trace-origin/) documentation.
309309

310-
```json
311-
{
312-
"sentry.origin": "auto.db.graphql"
313-
}
314-
```
310+
Logs can be generated in three ways:
311+
312+
1. User calls Sentry’s Logging API directly: No `sentry.origin`.
313+
314+
2. Captured from a 3rd-party logging library: Use `auto.log[...]` format.
315+
```json
316+
{ "sentry.origin": "auto.log.serilog" }
317+
```
318+
3. Auto-emitted logs from other instrumented systems: Use the matching trace origin category (e.g. db, http, etc.).
319+
```json
320+
{ "sentry.origin": "auto.db.prisma" }
321+
```
315322

316323
#### User Attributes
317324

develop-docs/sdk/telemetry/traces/span-operations.mdx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -265,6 +265,7 @@ Messages/Queue spans are expected follow OpenTelemetry's [Messaging](https://git
265265
| graphql | |
266266
| grpc | |
267267
| http | |
268+
| log | |
268269
| mark | |
269270
| measure | |
270271
| middleware | |

0 commit comments

Comments
 (0)