• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1/*
2 * Copyright (C) 2023 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 *      http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17syntax = "proto2";
18
19package android.os.statsd.wearservices;
20
21import "frameworks/proto_logging/stats/atoms.proto";
22import "frameworks/proto_logging/stats/atom_field_options.proto";
23import "frameworks/proto_logging/stats/enums/app/wearservices/wearservices_enums.proto";
24
25option java_package = "com.android.os.wearservices";
26option java_multiple_files = true;
27
28extend Atom {
29  // Pushed Atom
30  optional WsWearTimeSession ws_wear_time_session = 610
31      [(module) = "wearservices"];
32
33  optional WsIncomingCallActionReported ws_incoming_call_action_reported = 626
34      [(module) = "wearservices"];
35
36  optional WsCallDisconnectionReported ws_call_disconnection_reported = 627
37      [(module) = "wearservices"];
38
39  optional WsCallDurationReported ws_call_duration_reported = 628
40      [(module) = "wearservices"];
41
42  optional WsCallUserExperienceLatencyReported ws_call_user_experience_latency_reported = 629
43      [(module) = "wearservices"];
44
45  optional WsCallInteractionReported ws_call_interaction_reported = 630
46      [(module) = "wearservices"];
47
48  optional WsOnBodyStateChanged ws_on_body_state_changed = 787
49      [(module) = "wearservices"];
50
51  optional WsWatchFaceRestrictedComplicationsImpacted
52    ws_watch_face_restricted_complications_impacted = 802
53      [(module) = "wearservices"];
54
55  optional WsWatchFaceDefaultRestrictedComplicationsRemoved
56    ws_watch_face_default_restricted_complications_removed = 803
57      [(module) = "wearservices"];
58
59  optional WsComplicationsImpactedNotificationEventReported
60    ws_complications_impacted_notification_event_reported = 804
61      [(module) = "wearservices"];
62
63  optional WsRemoteEventUsageReported ws_remote_event_usage_reported = 920
64      [(module) = "wearservices"];
65
66  optional WsNotificationManagedDismissalSync ws_notification_managed_dismissal_sync = 941
67      [(module) = "wearservices"];
68
69  optional WsBugreportEventReported ws_bugreport_event_reported = 964
70      [(module) = "wearservices"];
71
72  optional WsNotificationApiUsageReported ws_notification_api_usage_reported = 1005
73      [(module) = "wearservices"];
74
75  optional WsRemoteInteractionsApiUsageReported ws_remote_interactions_api_usage_reported = 1012
76      [(module) = "wearservices"];
77
78  // Pulled Atom
79  optional WsStandaloneModeSnapshot ws_standalone_mode_snapshot = 10197
80      [(module) = "wearservices"];
81
82  optional WsFavouriteWatchFaceSnapshot ws_favorite_watch_face_snapshot = 10206
83      [(module) = "wearservices"];
84
85  optional WsPhotosWatchFaceFeatureSnapshot ws_photos_watch_face_feature_snapshot = 10225
86      [(module) = "wearservices"];
87
88  optional WsWatchFaceCustomizationSnapshot ws_watch_face_customization_snapshot = 10227
89      [(module) = "wearservices"];
90}
91
92/**
93 * Logged whenever an incoming call is accepted or rejected or silenced.
94 *
95 * Logged from package :
96 * vendor/google_clockwork_partners/packages/WearServices
97 */
98message WsIncomingCallActionReported {
99
100  // Depicts different call actions possible.
101  // Values: (CALL_ACTION_ACCEPTED, CALL_ACTION_REJECTED, CALL_ACTION_SILENCED)
102  optional android.app.wearservices.CallAction action = 1;
103
104  // Depicts different call account in use.
105  // Values: (CALL_SOURCE_WATCH, CALL_SOURCE_PHONE_HFP,
106  // CALL_SOURCE_PHONE_COMPANION)
107  optional android.app.wearservices.CallSource call_source = 2;
108}
109
110/**
111 * Logged whenever a call is disconnected.
112 *
113 * Logged from package :
114 * vendor/google_clockwork_partners/packages/WearServices
115 */
116message WsCallDisconnectionReported {
117
118  // Depicts Disconnection reason.
119  // Values: (DISCONNECT_REASON_ERROR, DISCONNECT_REASON_REJECTED, etc)
120  optional android.app.wearservices.DisconnectionReason reason = 1;
121
122  // Depicts the error behind the disconnection.
123  // Values: (DISCONNECTION_ERROR_CODE_DIALER,
124  // DISCONNECTION_ERROR_CODE_PHONE_DISCONNECTED, etc)
125  optional android.app.wearservices.DisconnectionErrorCode error_code = 2;
126}
127
128/**
129 * Logged whenever an incoming or outgoing call is bridged and picked up.
130 * The call picked up can be either on the watch, phone or via another connected
131 * device like bluetooth headphones.
132 *
133 * Logged from package :
134 * vendor/google_clockwork_partners/packages/WearServices
135 */
136message WsCallDurationReported {
137
138  // Depicts the type of call.
139  // Values: (CALL_TYPE_INCOMING, CALL_TYPE_OUTGOING)
140  optional android.app.wearservices.CallType call_type = 1;
141
142  // This field depicts whether the call was accepted or initiated on the watch.
143  // For OUTGOING calls it MUST be set to true when the call is initiated on the
144  // watch, for INCOMING calls it MUST be set to true when the call is accepted
145  // on the watch.
146  optional bool is_initiated_or_accepted_on_watch = 2;
147
148  // Depicts different call account in use.
149  // Values: (CALL_SOURCE_WATCH, CALL_SOURCE_PHONE_HFP,
150  // CALL_SOURCE_PHONE_COMPANION)
151  optional android.app.wearservices.CallSource call_source = 3;
152
153  // Depicts call duration in millis.
154  optional int32 call_duration_millis = 4;
155}
156
157/**
158 * Logged whenever a call request is received and bridged to the watch.
159 * This metric particularly measures the latency of different stages and actions
160 * during a call.
161 *
162 * Logged from package :
163 * vendor/google_clockwork_partners/packages/WearServices
164 */
165message WsCallUserExperienceLatencyReported {
166
167  // Depicts for what action the latency is being reported.
168  // Values: (LATENCY_ACTION_CALL_CREATION, LATENCY_ACTION_RING,
169  // LATENCY_ACTION_PICKED_CALL, LATENCY_ACTION_AUDIO_OUTPUT_SWITCH)
170  optional android.app.wearservices.LatencyAction latency_action = 1;
171
172  // Depicts the result of the overall call.
173  // Values: CALL_RESULT_NO_INTERACTION_ON_WATCH, CALL_RESULT_ACCEPTED_ON_WATCH,
174  // CALL_RESULT_REJECTED_ON_WATCH)
175  optional android.app.wearservices.CallResult result = 2;
176
177  // Depicts latency duration in millis.
178  optional int32 latency_duration_millis = 3;
179}
180
181/**
182 * Logged for call interactions in Wear Services.
183 *
184 * Logged from package :
185 * vendor/google_clockwork_partners/packages/WearServices
186 */
187message WsCallInteractionReported {
188
189  // Depicts user interaction during the call.
190  // Values: (CALL_INTERACTION_VOLUME_INCREASE,
191  // CALL_INTERACTION_VOLUME_DECREASE, CALL_INTERACTION_MUTE)
192  optional android.app.wearservices.CallInteraction interaction = 1;
193
194  // Depicts different call account in use.
195  // Values: (CALL_SOURCE_WATCH, CALL_SOURCE_PHONE_HFP,
196  // CALL_SOURCE_PHONE_COMPANION)
197  optional android.app.wearservices.CallSource call_source = 2;
198}
199
200/**
201 * Atom used to log the wear time for Wearables.
202 *
203 * Logged from package :
204 * vendor/google_clockwork_partners/packages/WearServices
205 */
206message WsWearTimeSession {
207    optional int64 session_duration_millis = 1;
208}
209
210/**
211 * Atom used to log that on body state of a Wearable have changed.
212 * Logged from package :
213 * vendor/google_clockwork_partners/packages/WearServices
214 */
215message WsOnBodyStateChanged {
216  optional android.app.wearservices.OnBodyState on_body_state = 1;
217  optional int64 sensor_event_timestamp_nanos = 2;
218}
219
220/**
221* A snapshot of the tether status on certain watches.
222* (go/wear-tether-mode-telemetry)
223*
224* Logged from package :
225* vendor/google_clockwork_partners/packages/WearServices
226*/
227message WsStandaloneModeSnapshot {
228  // Depicts the standalone/tether status of the watch.
229  optional android.app.wearservices.TetherConfigurationStatus tether_configuration_status = 1;
230}
231
232/**
233 * Logged for each watch face affected by the complication restrictions during
234 * upgrading to a build that supports the feature.
235 */
236message WsWatchFaceRestrictedComplicationsImpacted {
237  // Watch face package uid.
238  optional int32 watch_face_package_uid = 1 [(is_uid) = true];
239
240  // Watch face component class name.
241  optional string watch_face_component_class_name = 2;
242
243  // Complication component package UIDs for complications being restricted.
244  // A single watch face may have multiple restricted complications and each entry in this field
245  // corresponds to one of the restricted complications being removed.
246  repeated int32 complication_component_package_uid = 3 [(is_uid) = true];
247
248  // Complication component class names for complications being restricted corresponding to each
249  // restricted complication on the watch face.
250  repeated string complication_component_class_name = 4;
251
252  // Complication type (e.g. icon, small text) corresponding to the integer values defined in
253  // ComplicationData
254  // see: http://cs/h/googleplex-android/platform/frameworks/support/+/androidx-platform-release:wear/watchface/watchface-complications-data/src/main/java/android/support/wearable/complications/ComplicationData.kt
255  repeated int32 complication_type = 5;
256
257  // Indicates whether this watch face is the currently active watch face.
258  optional bool is_current_active = 6;
259}
260
261/**
262 * Snapshot of a favorite watch face with all of its complications.
263 */
264message WsFavouriteWatchFaceSnapshot {
265  // Active watch face package uid.
266  optional int32 watch_face_package_uid = 1 [(is_uid) = true];
267
268  // Active watch face class name. This will be
269  // null for Declarative WF packages, as these packages have only one WF.
270  optional string watch_face_class_name = 2;
271
272  // An ID number generated on a watch to uniquely identify watch face instances.
273  // An Androidx watch face can be added multiple times to the favorites list and this field is used
274  // to differentiate each instance, without leaking any information about the watch face itself.
275  // Note: equals to -1 in case of WSL watch faces.
276  optional int32 favorite_id = 3;
277
278  // Complication package name.
279  repeated int32 complication_component_package_uid = 4 [(is_uid) = true];
280
281  // Complication component class name.
282  repeated string complication_component_class_name = 5;
283
284  // Complication type (e.g. icon, small text) corresponding to the integer values defined in
285  // ComplicationData
286  // see: http://cs/h/googleplex-android/platform/frameworks/support/+/androidx-platform-release:wear/watchface/watchface-complications-data/src/main/java/android/support/wearable/complications/ComplicationData.kt
287  repeated int32 complication_type = 6;
288
289  // Indicates whether this watch face is the current active one.
290  optional bool is_current_active = 7;
291
292  // Indicates whether this watch face is restricted.
293  optional bool is_restricted = 8;
294}
295
296/**
297 * Snapshot for the types of watch face customizations done by the user till date.
298 */
299message WsWatchFaceCustomizationSnapshot {
300  // Indicates that the user customized a WF any time in the past.
301  optional bool customized_wf = 1;
302
303  // Indicates that the user switched to a pre-installed WF any time in the past.
304  optional bool switched_to_pre_installed_wf = 2;
305
306  // Indicates that the user switched to a non preinstalled WF any time in the past.
307  optional bool switched_to_non_preinstalled_wf = 3;
308}
309
310/**
311 * Snapshot of a photos watch face feature for the watch face favorite.
312 */
313message WsPhotosWatchFaceFeatureSnapshot {
314  // Watch face package uid.
315  optional int32 watch_face_package_uid = 1 [(is_uid) = true];
316
317  // An ID number generated on a watch to uniquely identify watch face instances.
318  // An Androidx watch face can be added multiple times to the favorites list and this field is used
319  // to differentiate each instance, without leaking any information about the watch face itself.
320  // Note: equals to -1 in case of WSL watch faces.
321  optional int32 favorite_id = 2;
322
323  // Contains types for photo selection.
324  optional android.app.wearservices.PhotoSelectionType photo_selection_type = 3;
325}
326
327/**
328 * Logged whenever a user adds a watch face to the list of favorites and it contains
329 * restricted default complications.
330 */
331message WsWatchFaceDefaultRestrictedComplicationsRemoved {
332  // Watch face package uid.
333  optional int32 watch_face_package_uid = 1 [(is_uid) = true];
334
335  // Watch face component class name.
336  optional string watch_face_component_class_name = 2;
337
338  // Complication component package uids for complications being restricted.
339  repeated int32 complication_component_package_uid = 3 [(is_uid) = true];
340
341  // Complication component class names for complications being restricted.
342  repeated string complication_component_class_name = 4;
343
344  // Complication type (e.g. icon, small text) corresponding to the integer values defined in
345  // ComplicationData
346  // see: http://cs/h/googleplex-android/platform/frameworks/support/+/androidx-platform-release:wear/watchface/watchface-complications-data/src/main/java/android/support/wearable/complications/ComplicationData.kt
347  repeated int32 complication_type = 5;
348
349  // Complication slot IDs being affected by the restriction.
350  // Each watch face defines some complication slots. Each slot corresponds to a complication that
351  // can be configured on the watch face (e.g. battery, steps). Slots on the same watch face are
352  // defined with unique IDs. Those IDs are not unique across devices.
353  repeated int32 slot_id = 6;
354
355  // Type of the watch face being affected by the restriction.
356  optional android.app.wearservices.WatchFaceType watch_face_type = 7;
357}
358
359/**
360 * Logged whenever a user gets the notification informing them that their watch faces are affected
361 * by the complications restrictions, or they click on the "open on phone" action.
362 */
363message WsComplicationsImpactedNotificationEventReported {
364  enum Event {
365    UNSPECIFIED = 0;
366
367    // Indicates that the notification is sent.
368    SENT = 1;
369
370    // Indicates that the user clicked through the notification to the help center.
371    CLICKED = 2;
372  }
373  optional Event event = 1;
374}
375
376/**
377 * Logged whenever a remote event is being sent to the companion.
378 *
379 * Logged from package :
380 * vendor/google_clockwork_partners/packages/WearServices
381 */
382message WsRemoteEventUsageReported {
383
384  // Indicates the type of remote event being reported.
385  optional android.app.wearservices.RemoteEventType remote_event_type = 1;
386
387  // Indicates the status of the remote event being sent.
388  // Note: This field is deprecated.
389  optional bool is_successful = 2 [deprecated = true];
390
391  // Indicates the state of the remote event.
392  optional android.app.wearservices.RemoteEventState remote_event_state = 3;
393}
394
395/** Logged when a bugreport event takes place. */
396message WsBugreportEventReported {
397
398  // Depicts the event that is being reported.
399  // Values: (EVENT_BUGREPORT_UNKNOWN, EVENT_BUGREPORT_REQUESTED, EVENT_BUGREPORT_TRIGGERED, EVENT_BUGREPORT_FINISHED, EVENT_BUGREPORT_RESULT_RECEIVED)
400  optional android.app.wearservices.BugreportEvent event = 1;
401
402  // Depicts the component involved in the bugreport flow.
403  // In the case of EVENT_BUGREPORT_REQUESTED, it refers to the component that requested the
404  // bugreport.
405  // In the case of EVENT_BUGREPORT_RESULT_RECEIVED, it refers to the component that received the
406  // bugreport result.
407  // It's set to BUGREPORT_COMPONENT_UNSET when the event is EVENT_BUGREPORT_TRIGGERED or
408  // EVENT_BUGREPORT_FINISHED.
409  // Values: (BUGREPORT_COMPONENT_UNKNOWN, BUGREPORT_COMPONENT_UNSET, BUGREPORT_COMPONENT_COMPANION_APP, BUGREPORT_COMPONENT_WATCH_UI)
410  optional android.app.wearservices.BugreportComponent component = 2;
411
412  // Depicts the result of the bugreport.
413  // It's set to BUGREPORT_RESULT_UNSET when the event is EVENT_BUGREPORT_REQUESTED or
414  // EVENT_BUGREPORT_TRIGGERED.
415  // Values: (BUGREPORT_RESULT_UNKNOWN, BUGREPORT_RESULT_UNSET, BUGREPORT_RESULT_SUCCESS, BUGREPORT_RESULT_FAILURE)
416  optional android.app.wearservices.BugreportResult result = 3;
417
418  // Depicts the size of the bugreport in kilobytes
419  // It's set to 0 when the event is EVENT_BUGREPORT_REQUESTED or EVENT_BUGREPORT_TRIGGERED.
420  optional int32 bugreport_size_kilobytes = 4;
421
422  // Depicts the duration of the bugreport event in seconds.
423  // It's set only for EVENT_BUGREPORT_FINISHED and EVENT_BUGREPORT_RESULT_RECEIVED.
424  optional int32 bugreport_event_duration_seconds = 5;
425
426  // Depics the failure reason in case the bugreport event contains a failure.
427  optional android.app.wearservices.BugreportFailureReason failure_reason = 6;
428}
429
430/** Logged when notification ID dismissal was synchronised between devices. */
431message WsNotificationManagedDismissalSync {
432  // Package name of the application that created the notification.
433  // We use package name instead of uid as the application may not be installed on the device.
434  optional string package_name = 1;
435
436  // Device that initiated the synchronisation.
437  optional android.app.wearservices.RequestSource source_device = 2;
438
439  // Size of the payload in bytes
440  optional int32 payload_size_bytes = 3;
441}
442
443/**
444 * Logged when notification API is called.
445 *
446 * Logged from:
447 * vendor/google_clockwork_partners/packages/WearServices/src/com/google/wear/services/notification/api/NotificationApiImpl.java
448 */
449message WsNotificationApiUsageReported {
450  // Name of the Notification API usage reported.
451  optional android.app.wearservices.NotificationApiName api_name = 1;
452
453  // Status of the Notification API usage reported.
454  optional android.app.wearservices.NotificationApiStatus api_status = 2;
455}
456
457/**
458 * Logged when remote interactions API is called.
459 *
460 * Logged from:
461 * vendor/google_clockwork_partners/packages/WearServices/src/com/google/wear/services/remoteinteractions
462 */
463message WsRemoteInteractionsApiUsageReported {
464  // Package uid of the application that created the remote interactions request.
465  optional int32 remote_interactions_package_uid = 1 [(is_uid) = true];
466
467  // Indicates the state of the remote interactions.
468  optional android.app.wearservices.RemoteInteractionsState remote_interactions_state = 2;
469}
470