-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[remote-storage][v2] Add proto definition for
GetTraces
rpc (#6730)
<!-- !! Please DELETE this comment before posting. We appreciate your contribution to the Jaeger project! 👋🎉 --> ## Which problem is this PR solving? - Towards #6629 ## Description of the changes - This PR creates a protobuf definition in `traces_storage.proto` that will contain the API for all methods pertaining to the traces storage. ## How was this change tested? - CI ## 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]>
- Loading branch information
1 parent
9266f00
commit 23d2254
Showing
3 changed files
with
347 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
syntax = "proto3"; | ||
|
||
package jaeger.storage.v2; | ||
|
||
import "gogoproto/gogo.proto"; | ||
import "google/protobuf/timestamp.proto"; | ||
import "opentelemetry/proto/trace/v1/trace.proto"; | ||
|
||
option go_package = "storage"; | ||
|
||
// GetTraceParams represents the query for a single trace from the storage backend. | ||
message GetTraceParams { | ||
// trace_id is a 16 byte array containing the unique identifier for the trace to query. | ||
bytes trace_id = 1; | ||
|
||
// start_time is the start of the time interval to search for the trace_id. | ||
// | ||
// This field is optional. | ||
google.protobuf.Timestamp start_time = 2 [ | ||
(gogoproto.stdtime) = true | ||
]; | ||
|
||
// end_time is the end of the time interval to search for the trace_id. | ||
// | ||
// This field is optional. | ||
google.protobuf.Timestamp end_time = 3 [ | ||
(gogoproto.stdtime) = true | ||
]; | ||
} | ||
|
||
// GetTracesRequest represents a request to retrieve multiple traces. | ||
message GetTracesRequest { | ||
repeated GetTraceParams query = 1; | ||
} | ||
|
||
service TraceReader { | ||
// GetTraces returns a stream that retrieves all traces with given IDs. | ||
// | ||
// Chunking requirements: | ||
// - A single TracesData chunk MUST NOT contain spans from multiple traces. | ||
// - Large traces MAY be split across multiple, *consecutive* TracesData chunks. | ||
// - Each returned TracesData object MUST NOT be empty. | ||
// | ||
// Edge cases: | ||
// - If no spans are found for any given trace ID, the ID is ignored. | ||
// - If none of the trace IDs are found in the storage, an empty response is returned. | ||
// - If an error is encountered, the stream returns the error and stops. | ||
rpc GetTraces(GetTracesRequest) returns (stream opentelemetry.proto.trace.v1.TracesData) {} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters