• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// Copyright 2024 Google Inc. All Rights Reserved.
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
15syntax = "proto3";
16
17package cas_metrics_proto;
18
19// Contains metrics pertaining to one artifact.
20message ArtifactMetrics {
21  string digest = 1;            // CAS root digest of the artifact ("hash/size").
22  int64 time_ms = 2;            // End to end time to upload the artifact.
23  int64 unzip_time_ms = 3;      // Time to unzip the artifact if it is a zip file.
24  int64 chunk_time_ms = 4;      // Time to chunk files if chunking is enabled.
25  int64 size_bytes = 5;         // Size of the artifact in bytes.
26  int64 uploaded_size_bytes = 6;// Size of uploaded entries in bytes.
27  int32 entries = 7;            // Number of entries.
28  int32 uploaded_entries = 8;   // Number of uploaded entries.
29}
30
31// Contains metrics for a CAS upload session.
32message CasMetrics {
33  int64 time_ms = 1;            // End to end time for the upload session.
34  repeated ArtifactMetrics artifacts = 2;
35  string client_version = 3;    // CAS uploader client version.
36  string uploader_version = 4;  // Content uploader (this script) version.
37  int32 max_workers = 5;        // Max workers used for uploading.
38}