• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// Copyright 2021 The ChromiumOS Authors
2// Use of this source code is governed by a BSD-style license that can be
3// found in the LICENSE file.
4
5syntax = "proto3";
6
7package chromiumos.test.api;
8
9option go_package = "go.chromium.org/chromiumos/config/go/test/api";
10
11import "chromiumos/longrunning/operations.proto";
12
13// Provides the ability to upload files to GS and publish results.
14// Publishing and upload require a more complex workflow than simple
15// file copy, and as such we require a service to simplify.
16service PublishService {
17  // UploadToGS uploads a folder to Google Cloud Storage
18  //
19  // Effectively this should function as a thin wrapper around the GCS API.
20  rpc UploadToGS(UploadToGSRequest)
21      returns (longrunning.Operation) {
22    option (longrunning.operation_info) = {
23      response_type: "UploadToGSResponse",
24      metadata_type: "UploadToGSMetadata"
25    };
26  }
27}
28
29message UploadToGSRequest {
30  // GS path to upload to, e.g. gs://foo/bar/baz/
31  string gs_directory = 1;
32
33  // Absolute path to local directory to upload to GS, e.g. /usr/local/foo/bar
34  string local_directory = 2;
35}
36
37message UploadToGSResponse {
38  // URL of Google Storage location containing offloaded files
39  string gs_url = 1;
40}
41
42message UploadToGSMetadata {
43}
44