| /* |
| * Copyright (C) 2021 The Android Open Source Project |
| * |
| * Licensed under the Apache License, Version 2.0 (the "License"); |
| * you may not use this file except in compliance with the License. |
| * You may obtain a copy of the License at |
| * |
| * http://www.apache.org/licenses/LICENSE-2.0 |
| * |
| * Unless required by applicable law or agreed to in writing, software |
| * distributed under the License is distributed on an "AS IS" BASIS, |
| * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| * See the License for the specific language governing permissions and |
| * limitations under the License. |
| */ |
| |
| // Partial clone packages/modules/StatsD/statsd/src/stats_log.proto. Unused messages are not copied |
| // here. |
| |
| syntax = "proto2"; |
| |
| package android.car.telemetry.statsd; |
| |
| option java_package = "com.android.car.telemetry"; |
| option java_outer_classname = "StatsLogProto"; |
| |
| import "packages/services/Car/service/src/com/android/car/telemetry/proto/atoms.proto"; |
| |
| message AggregatedAtomInfo { |
| optional Atom atom = 1; |
| repeated int64 elapsed_timestamp_nanos = 2; |
| } |
| |
| message EventMetricData { |
| optional int64 elapsed_timestamp_nanos = 1; |
| optional Atom atom = 2; |
| optional AggregatedAtomInfo aggregated_atom_info = 4; |
| reserved 3; |
| } |
| |
| message StatsLogReport { |
| optional int64 metric_id = 1; |
| |
| message EventMetricDataWrapper { |
| repeated EventMetricData data = 1; |
| } |
| |
| oneof data { |
| EventMetricDataWrapper event_metrics = 4; |
| } |
| |
| optional bool is_active = 14; |
| |
| reserved 2, 3, 5, 6, 7, 8, 9, 10, 11, 12, 13, 15, 16; |
| } |
| |
| message ConfigMetricsReport { |
| repeated StatsLogReport metrics = 1; |
| |
| enum DumpReportReason { |
| DEVICE_SHUTDOWN = 1; |
| CONFIG_UPDATED = 2; |
| CONFIG_REMOVED = 3; |
| GET_DATA_CALLED = 4; |
| ADB_DUMP = 5; |
| CONFIG_RESET = 6; |
| STATSCOMPANION_DIED = 7; |
| TERMINATION_SIGNAL_RECEIVED = 8; |
| } |
| optional DumpReportReason dump_report_reason = 8; |
| |
| reserved 2, 3, 4, 5, 6, 7, 9; |
| } |
| |
| message ConfigMetricsReportList { |
| message ConfigKey { |
| optional int32 uid = 1; |
| optional int64 id = 2; |
| } |
| optional ConfigKey config_key = 1; |
| |
| repeated ConfigMetricsReport reports = 2; |
| |
| reserved 10; |
| } |