blob: 49e15e561829c8cc31422081ffa08e754fe2ffc8 [file] [log] [blame]
// Copyright 2021 The LUCI Authors.
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// See the License for the specific language governing permissions and
// limitations under the License.
syntax = "proto3";
package cv.internal.tryjob;
option go_package = ";tryjob";
// UpdateTryjobTask checks the status of a Tryjob and updates its Datastore
// entity, and notifies Runs which care about this Tryjob.
// Queue: "tryjob-update".
message UpdateTryjobTask {
// id is the Tryjob entity datastore ID. Internal to CV.
int64 id = 1;
// external_id is the ID that identifies the Tryjob in the backend.
// e.g. in the case of buildbucket, it's the build ID.
string external_id = 2;
// CancelStaleTryjobs cancels all tryjobs that are intended to verify the given
// CL, that are now stale because a new non-trivial patchset has been uploaded.
// Queue: "cancel-stale-tryjobs"
message CancelStaleTryjobsTask {
// clid is the ID that identifies a CL entity. Internal to CV.
int64 clid = 1;
// previous_min_equiv_patchset is the patchset that stale tryjobs will be
// running at.
int32 previous_min_equiv_patchset = 2;
// current_min_equiv_patchset is the patchset at or after which the
// associated tryjobs are no longer considered stale.
int32 current_min_equiv_patchset = 3;
// ExecuteTryjobsPayload is the payload of the long op task that invokes
// the Tryjob Executor.
// The payload contains the event happens outside so that Tryjob Executor could
// react on the event.
// Exactly one event should be provided. Not using oneof for the sake of
// simplicity.
message ExecuteTryjobsPayload {
// RequirementChanged indicates the tryjobs requirement of the run has
// changed.
bool requirement_changed = 1;
// TryjobsUpdated contains ids of all tryjobs that have status update.
repeated int64 tryjobs_updated = 2;
// ExecuteTryjobsResult is the result of Tryjob executor.
message ExecuteTryjobsResult {
// TODO(yiwzhang): define