From cf0f82a8b19f1a8007c7ff2e40c84aa5bc6261d4 Mon Sep 17 00:00:00 2001 From: Abhijeet Prasad Date: Thu, 28 Aug 2025 11:07:59 -0400 Subject: [PATCH 1/2] feat: Update logs spec to mention message template constraint --- develop-docs/sdk/telemetry/logs.mdx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/develop-docs/sdk/telemetry/logs.mdx b/develop-docs/sdk/telemetry/logs.mdx index cd6821b727ae8a..2a8522203bcc6e 100644 --- a/develop-docs/sdk/telemetry/logs.mdx +++ b/develop-docs/sdk/telemetry/logs.mdx @@ -299,6 +299,8 @@ If the log was paramaterized the SDK should attach the following } ``` +If there are no `sentry.message.parameter.X` attributes included in the log, then the SDK MUST NOT attach a `sentry.message.template` attribute. + #### SDK Integration Attributes 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. From 08d797b7766053b859e65d790ba113b1c239a637 Mon Sep 17 00:00:00 2001 From: Abhijeet Prasad Date: Thu, 28 Aug 2025 11:10:54 -0400 Subject: [PATCH 2/2] Update develop-docs/sdk/telemetry/logs.mdx --- develop-docs/sdk/telemetry/logs.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/develop-docs/sdk/telemetry/logs.mdx b/develop-docs/sdk/telemetry/logs.mdx index 2a8522203bcc6e..296c048e9db3de 100644 --- a/develop-docs/sdk/telemetry/logs.mdx +++ b/develop-docs/sdk/telemetry/logs.mdx @@ -299,7 +299,7 @@ If the log was paramaterized the SDK should attach the following } ``` -If there are no `sentry.message.parameter.X` attributes included in the log, then the SDK MUST NOT attach a `sentry.message.template` attribute. +If there are no `sentry.message.parameter.X` attributes included in the log, then the SDK MUST NOT attach a `sentry.message.template` attribute. This is important because it reduces duplicate content in the log and makes PII processing in Sentry much easier as only we don't have to duplicate processing between the log message and the `sentry.message.template` attribute. #### SDK Integration Attributes