Skip to content

Commit 7460204

Browse files
committed
Add api_v3.GetDependenciesResponse and api_v3.GetDependenciesRequest
Signed-off-by: Sujal Shah <sujalshah28092004@gmail.com>
1 parent dcfa25a commit 7460204

File tree

2 files changed

+46
-0
lines changed

2 files changed

+46
-0
lines changed

proto/api_v3/query_service.proto

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -136,6 +136,22 @@ message GetOperationsResponse {
136136
repeated Operation operations = 1;
137137
}
138138

139+
message GetDependenciesRequest {
140+
google.protobuf.Timestamp end_time = 1;
141+
google.protobuf.Duration lookback = 2;
142+
}
143+
144+
message DependencyLink {
145+
string parent = 1;
146+
string child = 2;
147+
uint64 call_count = 3;
148+
}
149+
150+
message GetDependenciesResponse {
151+
repeated DependencyLink dependencies = 1;
152+
}
153+
154+
139155
service QueryService {
140156
// GetTrace returns a single trace.
141157
// Note that the JSON response over HTTP is wrapped into result envelope "{"result": ...}"
@@ -153,6 +169,10 @@ service QueryService {
153169

154170
// GetOperations returns operation names.
155171
rpc GetOperations(GetOperationsRequest) returns (GetOperationsResponse) {}
172+
173+
// GetDependencies returns dependencies.
174+
rpc GetDependencies(GetDependenciesRequest) returns (GetDependenciesResponse) {}
175+
156176
}
157177

158178
// Below are some helper types when using APIv3 via HTTP endpoints.

swagger/api_v3/query_service.swagger.json

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -296,6 +296,32 @@
296296
"description": "- STATUS_CODE_UNSET: The default status.\n - STATUS_CODE_OK: The Span has been validated by an Application developer or Operator to \nhave completed successfully.\n - STATUS_CODE_ERROR: The Span contains an error.",
297297
"title": "For the semantics of status codes see\nhttps://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/trace/api.md#set-status"
298298
},
299+
"api_v3DependencyLink": {
300+
"type": "object",
301+
"properties": {
302+
"parent": {
303+
"type": "string"
304+
},
305+
"child": {
306+
"type": "string"
307+
},
308+
"call_count": {
309+
"type": "string",
310+
"format": "uint64"
311+
}
312+
}
313+
},
314+
"api_v3GetDependenciesResponse": {
315+
"type": "object",
316+
"properties": {
317+
"dependencies": {
318+
"type": "array",
319+
"items": {
320+
"$ref": "#/definitions/api_v3DependencyLink"
321+
}
322+
}
323+
}
324+
},
299325
"api_v3GetOperationsResponse": {
300326
"type": "object",
301327
"properties": {

0 commit comments

Comments
 (0)