Skip to content

Commit

Permalink
[Quick Share QR Code] Log QR code session start and stop events
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 686196320
  • Loading branch information
hai007 authored and copybara-github committed Oct 17, 2024
1 parent 2183467 commit 2a34f47
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
5 changes: 4 additions & 1 deletion proto/sharing_enums.proto
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ option objc_class_prefix = "GNSHP";
// in NearbyClearcutLogger (for android, or clearcut_event_logger as the
// equivalence for Windows) for all events (may exclude settings), and
// session_id for a pair of events (start and end of a session).
// Next id: 70
// Next id: 71
enum EventType {
UNKNOWN_EVENT_TYPE = 0;

Expand Down Expand Up @@ -303,6 +303,9 @@ enum EventType {
// RPC call status
RPC_CALL_STATUS = 69;

// A QR code sharing session has started
START_QR_CODE_SESSION = 70;

// LINT.ThenChange(//depot/google3/location/nearby/proto/nearby_event_codes.proto:SharingEventCode)
}

Expand Down
8 changes: 7 additions & 1 deletion sharing/proto/analytics/nearby_sharing_log.proto
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ option objc_class_prefix = "GNCP";

// Top-level log proto for all NearbySharing logging.
// Each log contains a key (event_type), value (a verb-noun event) pair.
// Next Tag: 79
// Next Tag: 80
// LINT.IfChange
message SharingLog {
/* collection_basis = {
Expand Down Expand Up @@ -214,6 +214,8 @@ message SharingLog {

optional RpcCallStatus rpc_call_status = 78;

optional StartQrCodeSession start_qr_code_session = 79;

// Used only for Nearby Share Windows app now.
message AppInfo {
// e.g. "1.0.408"
Expand Down Expand Up @@ -360,6 +362,7 @@ message SharingLog {
optional location.nearby.proto.sharing.ScanType scan_type = 3;
optional int64 flow_id = 4 /* type = ST_SESSION_ID */;
optional string referrer_name = 5;
optional bool use_qr_code = 6;
}

// EventType: SCAN_FOR_SHARE_TARGETS_END
Expand Down Expand Up @@ -922,5 +925,8 @@ message SharingLog {
// Latency of RPC call in milliseconds.
optional int64 latency_millis = 4;
}

// EventType: START_QR_CODE_SESSION
message StartQrCodeSession {}
}
// LINT.ThenChange(//depot/google3/logs/proto/location/nearby/nearby_client_log.proto)

0 comments on commit 2a34f47

Please sign in to comment.