Skip to content

Commit b11f7dd

Browse files
authored
fix(subscription): Maybe APM fix? (#17059)
1 parent f5dcbe4 commit b11f7dd

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/sentry/snuba/query_subscription_consumer.py

+6-1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
import jsonschema
66
import pytz
77
import sentry_sdk
8+
from sentry_sdk.tracing import Span
89
from confluent_kafka import Consumer, KafkaException, TopicPartition
910
from dateutil.parser import parse as parse_date
1011
from django.conf import settings
@@ -186,7 +187,11 @@ def handle_message(self, message):
186187

187188
callback = subscriber_registry[subscription.type]
188189
with sentry_sdk.start_span(
189-
op="process_message", transaction="query_subscription_consumer_process_message"
190+
Span(
191+
op="process_message",
192+
transaction="query_subscription_consumer_process_message",
193+
sampled=True,
194+
)
190195
) as span, metrics.timer(
191196
"snuba_query_subscriber.callback.duration", instance=subscription.type
192197
):

0 commit comments

Comments
 (0)