Skip to content

Commit f79a819

Browse files
authored
feat(ourlogs): Use aliases in the frontend (#91467)
Update frontend renderers to use aliases from #91457
1 parent e7e2675 commit f79a819

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

static/app/views/explore/logs/constants.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ export const HiddenLogDetailFields: OurLogFieldKey[] = [
4242

4343
// deprecated/otel fields that clutter the UI
4444
'sentry.timestamp_nanos',
45+
'sentry.observed_timestamp_nanos',
4546
'tags[sentry.timestamp_precise,number]',
4647
'tags[sentry.trace_flags,number]',
4748
'span_id',

static/app/views/explore/logs/types.tsx

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ type OurLogCustomFieldKey = string; // We could brand this for nominal types.
1111

1212
// This enum is used to represent known fields or attributes in the logs response.
1313
// Should always map to the public alias from the backend (.../search/eap/ourlogs/attributes.py)
14+
// This is not an exhaustive list, it's only the fields which have special handling in the frontend
1415
export enum OurLogKnownFieldKey {
1516
TRACE_ID = 'trace',
1617
MESSAGE = 'message',
@@ -25,13 +26,14 @@ export enum OurLogKnownFieldKey {
2526
CODE_LINE_NUMBER = 'tags[code.line.number,number]',
2627
CODE_FUNCTION_NAME = 'code.function.name',
2728

29+
RELEASE = 'release',
30+
TEMPLATE = 'message.template',
31+
PARENT_SPAN_ID = 'trace.parent_span_id',
32+
SDK_NAME = 'sdk.name',
33+
SDK_VERSION = 'sdk.version',
34+
2835
// From the EAP dataset directly not using a column alias.
2936
ID = 'sentry.item_id',
30-
RELEASE = 'sentry.release',
31-
TEMPLATE = 'sentry.message.template',
32-
PARENT_SPAN_ID = 'sentry.trace.parent_span_id',
33-
SDK_NAME = 'sentry.sdk.name',
34-
SDK_VERSION = 'sentry.sdk.version',
3537

3638
// From the EAP dataset directly not using a column alias, should be hidden.
3739
ITEM_TYPE = 'sentry.item_type',

0 commit comments

Comments
 (0)