Skip to content

Commit 03d8e66

Browse files
committed
Refactor and rename a few types
1 parent 6cb9087 commit 03d8e66

File tree

1 file changed

+17
-21
lines changed

1 file changed

+17
-21
lines changed

proto/sentry_protos/snuba/v1/endpoint_get_traces.proto

Lines changed: 17 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -6,24 +6,25 @@ import "sentry_protos/snuba/v1/request_common.proto";
66
import "sentry_protos/snuba/v1/trace_item_attribute.proto";
77
import "sentry_protos/snuba/v1/trace_item_filter.proto";
88

9-
message TraceColumn {
10-
enum Name {
11-
NAME_UNSPECIFIED = 0;
12-
NAME_TRACE_ID = 1;
13-
NAME_START_TIMESTAMP = 2;
14-
NAME_ROOT_SPAN_NAME = 3;
15-
NAME_TOTAL_SPAN_COUNT = 4;
16-
NAME_FILTERED_SPAN_COUNT = 5;
17-
NAME_ROOT_SPAN_DURATION_MS = 6;
18-
}
9+
enum TraceAttributeKey {
10+
TRACE_ATTRIBUTE_KEY_UNSPECIFIED = 0;
11+
TRACE_ATTRIBUTE_KEY_TRACE_ID = 1;
12+
TRACE_ATTRIBUTE_KEY_START_TIMESTAMP = 2;
13+
TRACE_ATTRIBUTE_KEY_ROOT_SPAN_NAME = 3;
14+
TRACE_ATTRIBUTE_KEY_TOTAL_SPAN_COUNT = 4;
15+
TRACE_ATTRIBUTE_KEY_FILTERED_SPAN_COUNT = 5;
16+
TRACE_ATTRIBUTE_KEY_ROOT_SPAN_DURATION_MS = 6;
17+
}
1918

20-
Name name = 1;
19+
message TraceAttribute {
20+
TraceAttributeKey key = 1;
2121
AttributeKey.Type type = 2;
22+
AttributeValue value = 3;
2223
}
2324

2425
message GetTracesRequest {
2526
message OrderBy {
26-
TraceColumn column = 1;
27+
TraceAttributeKey key = 1;
2728
bool descending = 2;
2829
}
2930

@@ -36,22 +37,17 @@ message GetTracesRequest {
3637
PageToken page_token = 2;
3738
uint32 limit = 3;
3839

39-
repeated TraceItemFilter filters = 4;
40+
repeated TraceFilter filters = 4;
4041
repeated OrderBy order_by = 5;
41-
repeated TraceColumn columns = 6;
42+
repeated TraceAttribute attributes = 6;
4243
}
4344

4445
message GetTracesResponse {
4546
message Trace {
46-
message Column {
47-
TraceColumn.Name name = 1;
48-
AttributeValue value = 2;
49-
}
50-
51-
repeated Column columns = 1;
47+
repeated TraceAttribute attributes = 1;
5248
}
5349

54-
repeated Trace traces = 1;
50+
repeated Trace rows = 1;
5551

5652
PageToken page_token = 2;
5753
ResponseMeta meta = 3;

0 commit comments

Comments
 (0)