| // Copyright 2020 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 tast.cros.wilco; |
| |
| import "google/protobuf/empty.proto"; |
| |
| option go_package = "chromiumos/tast/services/cros/wilco"; |
| |
| // WilcoDtc provides RPC methods to interact with the Wilco VM and |
| // Support Daemon. |
| service WilcoService { |
| // GetStatus checks if services are running |
| rpc GetStatus(google.protobuf.Empty) |
| returns (GetStatusResponse) {} |
| |
| rpc RestartVM(RestartVMRequest) |
| returns (google.protobuf.Empty) {} |
| |
| // GetConfigurationData performs the grpc request from inside the VM |
| rpc GetConfigurationData(google.protobuf.Empty) |
| returns (GetConfigurationDataResponse) {} |
| // SendMessageToUi performs the grpc request from inside the VM |
| rpc SendMessageToUi(SendMessageToUiRequest) |
| returns (SendMessageToUiResponse) {} |
| |
| rpc TestPerformWebRequest(google.protobuf.Empty) |
| returns (google.protobuf.Empty) {} |
| |
| rpc ExecuteRoutine(ExecuteRoutineRequest) |
| returns (ExecuteRoutineResponse) {} |
| rpc TestRoutineCancellation(ExecuteRoutineRequest) |
| returns (google.protobuf.Empty) {} |
| rpc TestGetAvailableRoutines(google.protobuf.Empty) |
| returns (google.protobuf.Empty) {} |
| |
| rpc TestGetStatefulPartitionAvailableCapacity(google.protobuf.Empty) |
| returns (google.protobuf.Empty) {} |
| |
| rpc StartDPSLListener(StartDPSLListenerRequest) |
| returns (google.protobuf.Empty) {} |
| rpc StopDPSLListener(google.protobuf.Empty) |
| returns (google.protobuf.Empty) {} |
| rpc WaitForHandleConfigurationDataChanged(google.protobuf.Empty) |
| returns (google.protobuf.Empty) {} |
| rpc WaitForHandleMessageFromUi(google.protobuf.Empty) |
| returns (WaitForHandleMessageFromUiResponse) {} |
| } |
| |
| message GetStatusResponse { |
| uint64 wilco_dtc_supportd_pid = 1; // 0 means not running |
| uint64 wilco_dtc_pid = 2; // 0 means not running |
| } |
| |
| message RestartVMRequest { |
| bool start_processes = 1; |
| bool test_dbus_config = 2; |
| } |
| |
| message GetConfigurationDataResponse { |
| string json_configuration_data = 1; |
| } |
| |
| message SendMessageToUiRequest { |
| string json_message = 1; |
| } |
| |
| message SendMessageToUiResponse { |
| string response_json_message = 1; |
| } |
| |
| message ExecuteRoutineRequest { |
| // TODO(vsavu): replace with RunRoutineRequest from wilco_dtc_supportd.proto |
| bytes request = 1; |
| } |
| |
| enum DiagnosticRoutineStatus { |
| ROUTINE_STATUS_PASSED = 0; |
| ROUTINE_STATUS_FAILED = 1; |
| ROUTINE_STATUS_ERROR = 2; |
| ROUTINE_STATUS_CANCELLED = 3; |
| } |
| |
| message ExecuteRoutineResponse { |
| DiagnosticRoutineStatus status = 1; |
| } |
| |
| message StartDPSLListenerRequest { |
| string handle_message_from_ui_response = 1; |
| } |
| |
| message WaitForHandleMessageFromUiResponse { |
| string json_message = 1; |
| } |