-
Notifications
You must be signed in to change notification settings - Fork 231
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Duplicate Events fix - Add request ID and creation timestamp #1436
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Appended date in GMT format to branch_sdk_request_uuid in order to match it with Gateway format.
…stamp params from QR Code cache.
NidhiDixit09
changed the title
[IN PROGRESS] Duplicate Events fix - Add request ID and creation timestamp
Duplicate Events fix - Add request ID and creation timestamp
Oct 3, 2024
gdeluna-branch
approved these changes
Oct 4, 2024
gdeluna-branch
approved these changes
Oct 4, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Reference
SDK-2493 - Add unique id and timestamp to iOS SDK events
https://branch.atlassian.net/browse/SDK-2493
Summary
--
branch_sdk_request_creation_time_stamp
- Timestamp when the request object was created.--
branch_sdk_request_uuid
- unique identifier for request. It includes a UUID + Date in GMT locale. Date part is appended to match the format Gateway uses.Format : UUID + YYYYMMDDHH
Sample:
"branch_sdk_request_creation_time_stamp" : 1727927969748, "branch_sdk_request_uuid" : "40991413-1CF5-4B23-90B6-698204582872-2024100303",
Motivation
These fields will help in debugging and in uniquely identifying requests generated from SDK.
Type Of Change
Testing Instructions
Verify all unit tests pass.
Send Following Requests using SDK -
* INSTALL / OPEN ( v1/open , v1/install )
* STANDARD / CUSTOM EVENTS ( v2/event )
* GENERATE SHORL URL (v1/url)
Verify All Requests body contain following params -
branch_sdk_request_creation_time_stamp
branch_sdk_request_uuid
Verify
branch_sdk_request_uuid
is unique for all requests.* QR Code( v1/qr-code)
* Share Sheet (v1/url)
Verify Caching -
* Before Sending an event, turn off WIFI (internet).
* Note down
branch_sdk_request_uuid
andbranch_sdk_request_creation_time_stamp
of the request* Quit App, tune on WIFI cold-launch it again.
* App will re-send request which was failed in previous launch. Verify request has same
branch_sdk_request_uuid
andbranch_sdk_request_creation_time_stamp
Verify
branch_sdk_request_uuid
andbranch_sdk_request_creation_time_stamp
are persisted for all request types (Unit Tests -testUUIDANDTimeStampPersistence
)cc @BranchMetrics/saas-sdk-devs for visibility.