Skip to content

Commit ed39550

Browse files
committed
Revert some stuff
1 parent 2196b5c commit ed39550

File tree

2 files changed

+24
-3
lines changed

2 files changed

+24
-3
lines changed

sentry_sdk/integrations/opentelemetry/utils.py

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -130,6 +130,30 @@ def extract_span_data(span):
130130
if db_query:
131131
return span_data_for_db_query(span)
132132

133+
rpc_service = span.attributes.get(SpanAttributes.RPC_SERVICE)
134+
if rpc_service:
135+
return (
136+
span.attributes.get(SentrySpanAttribute.OP) or "rpc",
137+
description,
138+
status,
139+
http_status,
140+
origin,
141+
)
142+
143+
messaging_system = span.attributes.get(SpanAttributes.MESSAGING_SYSTEM)
144+
if messaging_system:
145+
return (
146+
span.attributes.get(SentrySpanAttribute.OP) or "message",
147+
description,
148+
status,
149+
http_status,
150+
origin,
151+
)
152+
153+
faas_trigger = span.attributes.get(SpanAttributes.FAAS_TRIGGER)
154+
if faas_trigger:
155+
return (str(faas_trigger), description, status, http_status, origin)
156+
133157
return (op, description, status, http_status, origin)
134158

135159

sentry_sdk/tracing.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1653,9 +1653,6 @@ def is_success(self):
16531653

16541654
def finish(self, end_timestamp=None):
16551655
# type: (Optional[Union[float, datetime]]) -> Optional[str]
1656-
if self.status is None:
1657-
self.set_status(SPANSTATUS.OK)
1658-
16591656
if end_timestamp is not None:
16601657
from sentry_sdk.integrations.opentelemetry.utils import (
16611658
convert_to_otel_timestamp,

0 commit comments

Comments
 (0)