Skip to content

Commit

Permalink
[query][api_v2/v_3] Add raw_traces parameter to GetTraceRequest and F…
Browse files Browse the repository at this point in the history
…indTracesRequest (#114)

## Which problem is this PR solving?
- Towards jaegertracing/jaeger#6417

## Description of the changes
- Added the `raw_traces` parameter to the `GetTraceRequest` and the
`TraceQueryParameters` in the `FindTracesRequest`

## Checklist
- [x] I have read
https://github.com/jaegertracing/jaeger/blob/master/CONTRIBUTING_GUIDELINES.md
- [x] I have signed all commits
- [x] I have added unit tests for the new functionality
- [x] I have run lint and test steps successfully
  - for `jaeger`: `make lint test`
  - for `jaeger-ui`: `npm run lint` and `npm run test`

---------

Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Yuri Shkuro <[email protected]>
Co-authored-by: Yuri Shkuro <[email protected]>
  • Loading branch information
mahadzaryab1 and yurishkuro authored Dec 26, 2024
1 parent de97430 commit 63f6e7e
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 0 deletions.
8 changes: 8 additions & 0 deletions proto/api_v2/query.proto
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@ message GetTraceRequest {
(gogoproto.stdtime) = true,
(gogoproto.nullable) = false
];
// Optional. If set to true, the response will not include any
// enrichments to the trace, such as clock skew adjustment.
// Instead, the trace will be returned exactly as stored.
bool raw_traces = 4;
}

message SpansResponseChunk {
Expand Down Expand Up @@ -112,6 +116,10 @@ message TraceQueryParameters {
(gogoproto.nullable) = false
];
int32 search_depth = 8;
// Optional. If set to true, the response will not include any
// enrichments to the trace, such as clock skew adjustment.
// Instead, the trace will be returned exactly as stored.
bool raw_traces = 9;
}

message FindTracesRequest {
Expand Down
10 changes: 10 additions & 0 deletions proto/api_v3/query_service.proto
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,11 @@ message GetTraceRequest {

// Optional. The end time to search trace ID.
google.protobuf.Timestamp end_time = 3;

// Optional. If set to true, the response will not include any
// enrichments to the trace, such as clock skew adjustment.
// Instead, the trace will be returned exactly as stored.
bool raw_traces = 4;
}

// Query parameters to find traces. Except for num_traces, all fields should be treated
Expand Down Expand Up @@ -72,6 +77,11 @@ message TraceQueryParameters {
// but not all implementations support such accuracy and for those
// the larger depth value simply means more traces returned.
int32 search_depth = 8;

// Optional. If set to true, the response will not include any
// enrichments to the trace, such as clock skew adjustment.
// Instead, the trace will be returned exactly as stored.
bool raw_traces = 9;
}

// Request object to search traces.
Expand Down
18 changes: 18 additions & 0 deletions swagger/api_v3/query_service.swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,13 @@
"required": false,
"type": "integer",
"format": "int32"
},
{
"name": "query.raw_traces",
"description": "Optional. If set to true, the response will not include any\nenrichments to the trace, such as clock skew adjustment.\nInstead, the trace will be returned exactly as stored.",
"in": "query",
"required": false,
"type": "boolean"
}
],
"tags": [
Expand Down Expand Up @@ -183,6 +190,13 @@
"required": false,
"type": "string",
"format": "date-time"
},
{
"name": "raw_traces",
"description": "Optional. If set to true, the response will not include any\nenrichments to the trace, such as clock skew adjustment.\nInstead, the trace will be returned exactly as stored.",
"in": "query",
"required": false,
"type": "boolean"
}
],
"tags": [
Expand Down Expand Up @@ -354,6 +368,10 @@
"type": "integer",
"format": "int32",
"description": "Maximum depth of search. Depending on the backend storage\nimplementtaion this could be like a regular LIMIT clause in SQL,\nbut not all implementations support such accuracy and for those\nthe larger depth value simply means more traces returned."
},
"raw_traces": {
"type": "boolean",
"description": "Optional. If set to true, the response will not include any\nenrichments to the trace, such as clock skew adjustment.\nInstead, the trace will be returned exactly as stored."
}
},
"description": "Query parameters to find traces. Except for num_traces, all fields should be treated\nas forming a conjunction, e.g., \"service_name='X' AND operation_name='Y' AND ...\".\nAll fields are matched against individual spans, not at the trace level.\nThe returned results contain traces where at least one span matches the conditions.\nWhen num_traces results in fewer traces returned, there is no required ordering.\n\nNote: num_traces should restrict the number of traces returned, but not all backends\ninterpret it this way. For instance, in Cassandra this limits the number of _spans_\nthat match the conditions, and the resulting number of traces can be less.\n\nNote: some storage implementations do not guarantee the correct implementation of all parameters."
Expand Down

0 comments on commit 63f6e7e

Please sign in to comment.