Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(774)

Unified Diff: scheduler/api/scheduler/v1/scheduler.proto

Issue 2948163002: scheduler: add GetJobInvocations api. (Closed)
Patch Set: grpc.error Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « scheduler/api/scheduler/v1/pb.discovery.go ('k') | scheduler/api/scheduler/v1/scheduler.pb.go » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: scheduler/api/scheduler/v1/scheduler.proto
diff --git a/scheduler/api/scheduler/v1/scheduler.proto b/scheduler/api/scheduler/v1/scheduler.proto
index 87acb32489f274e9068319f49609b312ba0c2f43..f7f037aa90b9ae81af1dde10f02eaa562318de06 100644
--- a/scheduler/api/scheduler/v1/scheduler.proto
+++ b/scheduler/api/scheduler/v1/scheduler.proto
@@ -12,7 +12,12 @@ service Scheduler {
// TODO: still in progress.
// GetJobs fetches all jobs satisfying JobsRequest and visibility ACLs.
+ // If JobsRequest.project is specified but the project doesn't exist, empty
+ // list of Jobs is returned.
rpc GetJobs(JobsRequest) returns (JobsReply);
+
+ // GetInvocations fetches invocations of a given job, most recent first.
+ rpc GetInvocations(InvocationsRequest) returns (InvocationsReply);
}
message JobsRequest {
@@ -35,3 +40,46 @@ message Job {
message JobState {
string ui_status = 1;
}
+
+
+message InvocationsRequest{
+ string project = 1;
+ string job = 2;
+ string cursor = 3;
+ // page_size defaults to 50 which is maximum.
+ int32 page_size = 4;
+}
+
+message InvocationsReply{
+ repeated Invocation invocations = 1;
+ string next_cursor = 2;
+}
+
+message Invocation {
+ int64 id = 1;
+ string job = 2;
+ string project = 3;
+
+ // TODO(tandrii): consider exposing InvocationNonce and RetryCount as these
+ // could be important to consumers of API in order to combine multiple
+ // attempts of what was supposed to be just one invocation.
+
+ // start_ts is unix timestamp in microseconds.
+ int64 started_ts = 4;
+ // finished_ts is unix timestamp in microseconds. Set only if final is true.
+ int64 finished_ts = 5;
+ // triggered_by is an identity ("kind:value") which is specified only if
+ // invocation was triggered by not the scheduler service itself.
+ string triggered_by = 6;
+ // Latest status of a job.
+ string status = 7;
+ // If true, the status of the job is final and won't change.
+ bool final = 8;
+
+ // config_revision pins project/job config version according to which this
+ // invocation was created.
+ string config_revision = 9;
+
+ // view_url points to human readable page for a given invocation if available.
+ string view_url = 10;
+}
« no previous file with comments | « scheduler/api/scheduler/v1/pb.discovery.go ('k') | scheduler/api/scheduler/v1/scheduler.pb.go » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698