From 8d4a16cfc6fd7bad916c41faea3740290e182d51 Mon Sep 17 00:00:00 2001 From: Hector Dearman Date: Tue, 19 Nov 2019 16:28:59 +0000 Subject: [PATCH] Reland Perfetto upload logging atoms DO NOT MERGE Initial state: - I landed ag/9652310 (the original change) downstream - I cherry-picked this change on upstream to aosp/1158971 - This cherry-pick had an incorrect Merged-In tag referring to ag/7911242 - This cl was present between mirror-aosp-master and master internally Branch CL aosp/master (aosp/1158971) \/ internal/mirror-aosp-master (aosp/1158971) \/ internal/[---] Nothing since ag/7911242 was here || already automerger skipped our change \/ internal/master (ag/9652310) \/ [various children] (ag/9652310) See: https://android-build.googleplex.com/builds/automerger/graph/project/googleplex-android/platform/frameworks/base How this will fix the issue: - The revert will go everywhere aosp/1158971 did - The reland will go everywhere aosp/1158971 did plus to internal/master This reverts commit 8ed72df3d8e21c06d8b1b848d6e58c15b251d25a. --- cmds/statsd/src/atoms.proto | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/cmds/statsd/src/atoms.proto b/cmds/statsd/src/atoms.proto index 847c2981ec8d5..8a8df38c65b2b 100644 --- a/cmds/statsd/src/atoms.proto +++ b/cmds/statsd/src/atoms.proto @@ -324,6 +324,8 @@ message Atom { AppCompatibilityChangeReported app_compatibility_change_reported = 228 [(allow_from_any_uid) = true]; + PerfettoUploaded perfetto_uploaded = + 229 [(log_from_module) = "perfetto"]; } // Pulled events will start at field 10000. @@ -6857,3 +6859,37 @@ message AppCompatibilityChangeReported { optional Source source = 4; } + +/** + * Logged from + * external/perfetto/src/perfetto_cmd/perfetto_cmd.cc + */ +message PerfettoUploaded { + enum Event { + PERFETTO_UNDEFINED = 0; + PERFETTO_TRACE_BEGIN = 1; + PERFETTO_BACKGROUND_TRACE_BEGIN = 2; + PERFETTO_ON_CONNECT = 3; + PERFETTO_ON_TRACING_DISABLED = 4; + PERFETTO_UPLOAD_DROPBOX_BEGIN = 5; + PERFETTO_UPLOAD_DROPBOX_SUCCESS = 6; + PERFETTO_UPLOAD_DROPBOX_FAILURE = 7; + PERFETTO_UPLOAD_INCIDENT_BEGIN = 8; + PERFETTO_UPLOAD_INCIDENT_SUCCESS = 9; + PERFETTO_UPLOAD_INCIDENT_FAILURE = 10; + PERFETTO_FINALIZE_TRACE_AND_EXIT = 11; + PERFETTO_TRIGGER_BEGIN = 12; + PERFETTO_TRIGGER_SUCCESS = 13; + PERFETTO_TRIGGER_FAILURE = 14; + PERFETTO_HIT_GUARDRAILS = 15; + PERFETTO_ON_TIMEOUT = 16; + PERFETTO_NOT_UPLOADING_EMPTY_TRACE = 17; + } + + // Which stage of the pipeline we are reporting from. + optional Event event = 1; + + // UUID matching the one set inside the SystemInfo trace packet. + optional int64 trace_uuid_lsb = 2; + optional int64 trace_uuid_msb = 3; +}