| // Copyright 2019 The Chromium OS Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| |
| syntax = "proto3"; |
| |
| package test_platform.phosphorus; |
| |
| option go_package = "go.chromium.org/chromiumos/infra/proto/go/test_platform/phosphorus"; |
| |
| import "google/protobuf/timestamp.proto"; |
| import "test_platform/phosphorus/common.proto"; |
| |
| // PrejobRequest defines the input of `phosphorus prejob`. |
| message PrejobRequest { |
| Config config = 1; |
| |
| string dut_hostname = 2; |
| |
| map<string,string> provisionable_labels = 3 [deprecated = true]; |
| |
| // What needs to be installed onto the DUT at the end of prejob, e.g. |
| // "cros-version": "reef-release/R77-12345.0.0". |
| map<string,string> desired_provisionable_labels = 4; |
| |
| // What is installed on the DUT before the prejob, e.g. |
| // "cros-version": "reef-release/R77-12345.0.0". |
| map<string,string> existing_provisionable_labels = 5; |
| |
| // Hard deadline for execution. |
| // |
| // All prejob execution should abort beyond this deadline. |
| google.protobuf.Timestamp deadline = 6; |
| } |
| |
| // PrejobResponse defines the output of `phosphorus prejob`. |
| message PrejobResponse { |
| // Values should be consistent with https://aip.dev/216 |
| enum State { |
| // Should not be used. |
| STATE_UNSPECIFIED = 0; |
| // The prejob succeeded. |
| // |
| // Some prejob failures may not be detectable during execution. These |
| // failures will be detected when parsing results off the prejob logs in a |
| // later step of test_runner. |
| SUCCEEDED = 1; |
| // The prejob failed. |
| FAILED = 2; |
| // The prejob hit the requested timeout. |
| TIMED_OUT = 3; |
| // The prejob was aborted externally. |
| ABORTED = 4; |
| } |
| |
| // `phosphorus prejob` exits with exit code 0 unless there is an |
| // infrastructure failure. When the exit code is 0, `state` indicates the |
| // best known state of the prejob execution (see comments on State enum). |
| State state = 1; |
| } |