1// Copyright 2014 The Chromium Authors 2// Use of this source code is governed by a BSD-style license that can be 3// found in the LICENSE file. 4 5syntax = "proto2"; 6 7option optimize_for = LITE_RUNTIME; 8option java_package = "org.chromium.components.metrics"; 9 10option java_outer_classname = "CastLogsProtos"; 11 12package metrics; // Cast-enabled device specific log data included in ChromeUserMetricsExtension. 13 14// Next tag: 9 15message CastLogsProto { 16 // Cast specific device information. 17 // Next tag: 7 18 message CastDeviceInfo { 19 // The product type of Cast device sent from Cast-enabled devices. 20 // Next tag: 14 21 enum CastProductType { 22 CAST_PRODUCT_TYPE_UNKNOWN = 0; 23 CAST_PRODUCT_TYPE_CHROMECAST = 1; 24 CAST_PRODUCT_TYPE_TV = 2; 25 CAST_PRODUCT_TYPE_AUDIO = 3; 26 CAST_PRODUCT_TYPE_ANDROID_TV = 4; 27 CAST_PRODUCT_TYPE_ASSISTANT = 5; 28 CAST_PRODUCT_TYPE_ANDROID_THINGS = 6; 29 CAST_PRODUCT_TYPE_CHROME_OS = 7; 30 CAST_PRODUCT_TYPE_FUCHSIA_OS = 8; 31 CAST_PRODUCT_TYPE_LITE = 9; 32 CAST_PRODUCT_TYPE_CORE = 10; 33 CAST_PRODUCT_TYPE_11 = 11; 34 CAST_PRODUCT_TYPE_ANDROID_AUTOMOTIVE = 12; 35 CAST_PRODUCT_TYPE_ANDROID = 13; 36 } 37 38 optional CastProductType type = 1; 39 40 // The hardware revision of each product. 41 optional string hardware_revision = 2; 42 43 // The manufacturer of Cast device, this value is empty when the device 44 // is manufactured by Google. 45 optional string manufacturer = 3; 46 47 // The model of the Cast device. 48 optional string model = 4; 49 50 // The serial number. 51 optional string serial_number = 5; 52 53 // Hardware information stored in factory partition. 54 // Next Tag: 12 55 message HardwareInfo { 56 optional string color = 1; 57 58 optional string mic = 2; 59 60 optional string memory = 3; 61 62 optional string nand = 4; 63 64 optional string mfg_date = 5; 65 66 optional string build_name = 6; 67 68 optional string config = 7; 69 70 optional string emmc = 8; 71 72 optional string display = 9; 73 74 optional string amp = 10; 75 76 optional string board_name = 11; 77 } 78 optional HardwareInfo hardware_info = 6; 79 } 80 81 // The device sends this information at least once per day. 82 optional CastDeviceInfo cast_device_info = 1; 83 84 // Information about Cast V2 API connection between sender application and 85 // Cast-enabled device. 86 // Next tag: 4 87 message CastConnectionInfo { 88 optional fixed32 transport_connection_id = 1; 89 90 optional fixed32 virtual_connection_id = 2; 91 92 // This message describes a detail sender device and sdk. 93 // Next tag: 10 94 message SenderInfo { 95 // The identifier for the sender device, that is pseudonymous and can be 96 // reset. This id has no link to a specific user or device. 97 optional fixed64 sender_device_id = 1; 98 99 // SDK type the sender application was using. 100 // Next tag: 3 101 enum SDKType { 102 SDK_UNKNOWN = 0; 103 104 // Native SDK type, 105 // E.G. Android sdk, iOS sdk. 106 SDK_NATIVE = 1; 107 108 // SDK via Chrome extension. 109 SDK_CHROME_EXTENSION = 2; 110 } 111 optional SDKType sdk_type = 2; 112 113 // Version of sender sdk/extension used to connection. The format varies 114 // by each platform. 115 optional string version = 3; 116 117 // Chrome browser version where the Chrome extension running. 118 // Only Chrome extension sends this information. 119 optional string chrome_browser_version = 4; 120 121 // Platform of sender device. 122 // Next tag: 8 123 enum Platform { 124 // Any platform other then cases below. 125 PLATFORM_OTHER = 0; 126 127 PLATFORM_ANDROID = 1; 128 PLATFORM_IOS = 2; 129 PLATFORM_WINDOWS = 3; 130 PLATFORM_OSX = 4; 131 PLATFORM_CHROMEOS = 5; 132 PLATFORM_LINUX = 6; 133 134 // The sender is Cast device - including itself. 135 PLATFORM_CAST = 7; 136 } 137 optional Platform platform = 5; 138 139 // Sender device system version. 140 optional string system_version = 6; 141 142 // What type of connection type used to establish between sender and 143 // receiver. 144 enum ConnectionType { 145 CONNECTION_TYPE_UNKNOWN = 0; 146 147 // A connection established directly between sender and receiver. 148 CONNECTION_TYPE_LOCAL = 1; 149 150 // A connection created by opencast to the device via the cloud relay. 151 CONNECTION_TYPE_RELAY = 2; 152 153 // A connection created by receiver itself internally. 154 CONNECTION_TYPE_INTERNAL = 3; 155 } 156 optional ConnectionType transport_connection_type = 7; 157 158 // Sender device model. 159 optional string model = 8; 160 161 // Last 2 bytes of the sender’s local IP addresses (both IP4/IP6) when 162 // the sender connected. This field stores ip fragment to last 2 bytes and 163 // first 2 bytes won't be used. 164 optional int32 sender_local_ip_fragment = 9; 165 } 166 optional SenderInfo sender_info = 3; 167 } 168 169 // Virtual connection established between sender application and Cast device. 170 repeated CastConnectionInfo cast_connection_info = 2; 171 172 // Stores Cast-enabled device specific events with a various context data. 173 // Next tag: 29 174 message CastEventProto { 175 // The name of the action, hashed by same logic used to hash user action 176 // event and histogram. 177 optional fixed64 name_hash = 1; 178 179 // The timestamp for the event, in milliseconds. 180 optional int64 time_msec = 2; 181 182 // The Cast receiver app ID related with this event. 183 optional fixed32 app_id = 3; 184 185 // The app ID of a remote Cast receiver associated with this event. 186 optional fixed32 remote_app_id = 19; 187 188 // The identifier for receiver application session. 189 optional fixed64 application_session_id = 4; 190 191 // Receiver side Cast SDK version. 192 optional fixed64 cast_receiver_version = 5; 193 194 // Cast MPL version. 195 optional fixed64 cast_mpl_version = 9; 196 197 // transport_connection_id related with this event. 198 optional fixed32 transport_connection_id = 6; 199 200 // virtual_connection_id related with this event. 201 optional fixed32 virtual_connection_id = 7; 202 203 // An optional value for the associated event, often a measurement in 204 // milliseconds. 205 optional int64 value = 8; 206 207 // Group id of Multizone Audio. 208 optional fixed64 group_uuid = 10; 209 210 optional string conversation_key = 11; 211 212 // Request id of V2 Application Protocol 213 optional fixed32 request_id = 12; 214 215 optional string event_id = 13; 216 217 optional string aogh_request_id = 16; 218 219 optional int64 aogh_local_device_id = 18; 220 221 optional string aogh_agent_id = 21; 222 223 optional string aogh_standard_agent_id = 28; 224 225 // Optional value associated with the event. For example, may be used for 226 // error codes. 227 message Metadata { 228 optional fixed64 name_hash = 1; 229 optional int64 value = 2; 230 } 231 repeated Metadata metadata = 14; 232 233 // Optional values associated with the event. 234 repeated float feature_vector = 15; 235 236 // Optional value associated with timezone update event. 237 optional string timezone_id = 17; 238 239 // Optional value to log ui version. 240 optional string ui_version = 20; 241 242 // Optional field to log SELINUX audit detail. 243 optional string selinux_audit_detail = 22; 244 245 // List of event ids belonging to a particular interaction. One interaction 246 // could receive multiple assistant outputs, hence multiple event ids. 247 repeated string event_id_list = 23; 248 249 // Duo core version. 250 optional fixed64 duo_core_version = 24; 251 252 // Model version of hotword detector. 253 optional string hotword_model_id = 25; 254 255 enum LaunchFrom { 256 FROM_UNKNOWN = 0; 257 // Launched by itself, or by the user interacting directly with the 258 // receiver device (e.g. use a TV remote to launch an app on Android TV). 259 FROM_LOCAL = 1; 260 // Launched by a Cast V1 sender using DIAL. 261 FROM_DIAL = 2; 262 // Launched by a Cast V2 sender device. 263 FROM_CAST_V2 = 3; 264 // Launched from the cloud. 265 FROM_CCS = 4; 266 } 267 optional LaunchFrom launch_from = 26; 268 269 enum RuntimeType { 270 RUNTIME_TYPE_UNKNOWN = 0; 271 RUNTIME_TYPE_CAST_WEB = 1; 272 RUNTIME_TYPE_CAST_LITE = 2; 273 RUNTIME_TYPE_NATIVE = 3; 274 } 275 // The Cast Core runtime type associated with this event. 276 optional RuntimeType runtime_type = 27; 277 } 278 repeated CastEventProto cast_event = 3; 279 280 // Virtual release track for releases sent to partners, trusted beta 281 // testers, developers, etc. 282 optional fixed32 virtual_release_track = 4; 283 284 // Cast specific device information which is expected to change over time. 285 // Next tag: 13 286 message CastDeviceMutableInfo { 287 // This is the last type of reboot the device encountered 288 // Next tag: 22 289 enum RebootType { 290 REBOOT_TYPE_UNKNOWN = 0; // Fail to get reboot type from system property 291 REBOOT_TYPE_FORCED = 1; // Power removed from device 292 REBOOT_TYPE_API = 2; // Requested from reboot setup api 293 REBOOT_TYPE_NIGHTLY = 3; 294 REBOOT_TYPE_OTA = 4; 295 REBOOT_TYPE_WATCHDOG = 5; // Reboot caused by a watchdog process. 296 REBOOT_TYPE_PROCESS_MANAGER = 6; 297 REBOOT_TYPE_CRASH_UPLOADER = 7; 298 REBOOT_TYPE_FDR = 8; 299 REBOOT_TYPE_HW_WATCHDOG = 9; 300 REBOOT_TYPE_SW_OTHER = 10; 301 REBOOT_TYPE_OVERHEAT = 11; 302 // The device got into a state such that it needs to regenerate the cloud 303 // device id. 304 REBOOT_TYPE_REGENERATE_CLOUD_ID = 12; 305 // Reboot triggered due to successive OOM events. 306 REBOOT_TYPE_REPEATED_OOM = 13; 307 // Reboot triggered when the utility process is found to be in 308 // crash loop. 309 REBOOT_TYPE_UTILITY_PROCESS_CRASH = 14; 310 // design doc go/fuchsia-session-restart-metrics 311 // Restart triggered due to graceful component teardown by the Fuchsia 312 // platform. Device has not rebooted. 313 REBOOT_TYPE_GRACEFUL_RESTART = 15; 314 // Restart triggered due to ungraceful component teardown by the Fuchsia 315 // platform. Device has not rebooted. 316 REBOOT_TYPE_UNGRACEFUL_RESTART = 16; 317 MULTI_SERVICE_BUG = 17; 318 POWER_MANAGER = 18; 319 EXPERIMENT_CHANGE = 19; 320 ANOMALY_DETECTION = 20; 321 KERNEL_PANIC = 21; 322 } 323 optional RebootType last_reboot_type = 1; 324 325 // System version which the cast_shell is running. 326 optional fixed64 system_build_number = 2; 327 328 // An identifier that is specific to the combination of app and device, in 329 // this case the one used by backdrop. 330 optional string backdrop_app_device_id = 3; 331 332 // Chromecast release version like "1.23", "1.24". The format is "X.Y" 333 // where X is major version and Y is sub major version. 334 optional fixed32 release_version = 4; 335 336 // IP version of the primary network interface. 337 enum NetifIPVersion { 338 IP_UNKNOWN = 0; 339 IP_V4 = 1; 340 IP_V6 = 2; 341 IP_DUAL_STACK = 3; 342 } 343 optional NetifIPVersion netif_ip_version = 5; 344 345 // True if the system which cast_shell is running on, supports ip dual stack 346 // sockets. 347 optional bool ip_dual_stack_supported = 6; 348 349 // Current timezone which the device is using. 350 optional string timezone_id = 7; 351 // Optional value to log latest ui version. 352 optional string latest_ui_version = 8; 353 354 // Station ID of the device if connected to Google WiFi network 355 optional string google_wifi_station_shmac = 9; 356 357 // Optional field to log installed manifest platform version. 358 optional string installed_manifest_platform_version = 10; 359 360 // Optional field to log installed manifest version. 361 optional uint32 installed_manifest_version = 11; 362 363 // Optional field to log the system bundle version. 364 optional string system_bundle_version = 12; 365 } 366 // The device sends this information at least once per day. 367 optional CastDeviceMutableInfo cast_device_mutable_info = 5; 368 369 optional fixed64 receiver_metrics_id = 6; 370 371 // This ID is only ever recorded for Google-internal users (dogfooders). It 372 // is never recorded for external users." 373 optional uint64 ephemeral_id = 7; 374 375 optional fixed32 source_virtual_release_track = 8; 376} 377