go.chromium.org/luci@v0.0.0-20240309015107-7cdc2e660f33/resultdb/sink/proto/v1/sink.proto (about)

     1  // Copyright 2019 The LUCI Authors.
     2  //
     3  // Licensed under the Apache License, Version 2.0 (the "License");
     4  // you may not use this file except in compliance with the License.
     5  // You may obtain a copy of the License at
     6  //
     7  //      http://www.apache.org/licenses/LICENSE-2.0
     8  //
     9  // Unless required by applicable law or agreed to in writing, software
    10  // distributed under the License is distributed on an "AS IS" BASIS,
    11  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    12  // See the License for the specific language governing permissions and
    13  // limitations under the License.
    14  
    15  syntax = "proto3";
    16  
    17  package luci.resultsink.v1;
    18  
    19  import "google/protobuf/empty.proto";
    20  import "go.chromium.org/luci/resultdb/sink/proto/v1/test_result.proto";
    21  
    22  option go_package = "go.chromium.org/luci/resultdb/sink/proto/v1;sinkpb";
    23  
    24  // Service to report test results.
    25  //
    26  // Note that clients need to add the auth token in the HTTP header when invoking
    27  // the RPCs of this service, or Unauthenticated error will be returned.
    28  // i.e., Authorization: ResultSink <auth-token>
    29  //
    30  // The auth token is available via resultdb.resultsink.auth_token LUCI_CONTEXT
    31  // value. For more information, visit
    32  // https://github.com/luci/luci-py/blob/master/client/LUCI_CONTEXT.md
    33  service Sink {
    34    // Reports test results.
    35    rpc ReportTestResults(ReportTestResultsRequest)
    36        returns (ReportTestResultsResponse) {};
    37  
    38    // Reports invocation-level artifacts.
    39    // To upload result-level artifact, use ReportTestResults instead.
    40    rpc ReportInvocationLevelArtifacts(ReportInvocationLevelArtifactsRequest)
    41        returns (google.protobuf.Empty) {};
    42  }
    43  
    44  message ReportTestResultsRequest {
    45    // Test results to report.
    46    repeated TestResult test_results = 1;
    47  }
    48  
    49  message ReportTestResultsResponse {
    50    // List of unique identifiers that can be used to link to these results
    51    // or requested via luci.resultdb.v1.ResultDB service.
    52    repeated string test_result_names = 1;
    53  }
    54  
    55  message ReportInvocationLevelArtifactsRequest {
    56    // Invocation-level artifacts to report.
    57    // The map key is an artifact id.
    58    map<string, Artifact> artifacts = 1;
    59  }