Skip to content
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

Make the session id not depend on fetching the fid #6152

Merged
merged 2 commits into from
Aug 12, 2024
Merged

Conversation

mrober
Copy link
Contributor

@mrober mrober commented Aug 2, 2024

Make generating a session id not depend on fetching the fid. This is needed so we can allow the common worker to initialize, and start accepting use actions, before any data collection, settings, or fid validation happens.

The hash of the crashlytics installation id was used to pad the length and increase entropy. Instead of that, we use a random uuid now. Verified nothing depends on the source of that padding by manually setting it to all 0s and doing an end-to-end test.

The way the session id is built is a little bit weird, using bytes. In the future, we could rewrite this to use proper string formatting.

Copy link
Contributor

github-actions bot commented Aug 2, 2024

Release note changes

The following release notes were modified. Please ensure they look correct.

Release Notes
firebase-crashlytics
### {{crashlytics}} version 19.0.4 {: #crashlytics_v19-0-4}

* {{feature}} Added the `isCrashlyticsCollectionEnabled` API to check if Crashlytics collection is enabled.
  ([Github #5919](//github.com/firebase/firebase-android-sdk/issues/5919))

* {{fixed}} Ensure that on-demand fatal events are never processed on the main thread.

* {{changed}} Internal changes to the way session IDs are generated.

#### {{crashlytics}} Kotlin extensions version 19.0.4 {: #crashlytics-ktx_v19-0-4}

The Kotlin extensions library transitively includes the updated
`firebase-crashlytics` library. The Kotlin extensions library has no additional
updates.

Copy link
Contributor

github-actions bot commented Aug 2, 2024

📝 PRs merging into main branch

Our main branch should always be in a releasable state. If you are working on a larger change, or if you don't want this change to see the light of the day just yet, consider using a feature branch first, and only merge into the main branch when the code complete and ready to be released.

@google-oss-bot
Copy link
Contributor

google-oss-bot commented Aug 2, 2024

Copy link
Contributor

github-actions bot commented Aug 2, 2024

Unit Test Results

  8 files   -    178    8 suites   - 178   25s ⏱️ - 4m 6s
22 tests  - 1 212  22 ✔️  - 1 196  0 💤  - 16  0 ±0 
44 runs   - 2 448  44 ✔️  - 2 416  0 💤  - 32  0 ±0 

Results for commit 3ee8545. ± Comparison against base commit 57aaf39.

♻️ This comment has been updated with latest results.

@google-oss-bot
Copy link
Contributor

google-oss-bot commented Aug 2, 2024

Size Report 1

Affected Products

  • firebase-crashlytics

    TypeBase (57aaf39)Merge (37167c1)Diff
    aar417 kB417 kB-59 B (-0.0%)
    apk (aggressive)697 kB697 kB+36 B (+0.0%)
    apk (release)5.85 MB5.85 MB-28 B (-0.0%)

Test Logs

  1. https://storage.googleapis.com/firebase-sdk-metric-reports/UuUsizlrAn.html

@google-oss-bot
Copy link
Contributor

google-oss-bot commented Aug 2, 2024

Startup Time Report 1

Note: Layout is sometimes suboptimal due to limited formatting support on GitHub. Please check this report on GCS.

Notes

Startup Times

  • fire-cls

    DeviceStatisticsDistributions
    oriole-32
    Percentile57aaf3937167c1DiffSignificant (?)
    p1011.2 ±3 ms11.2 ±2 ms+14.5 μs (+0.1%)NO
    p2511.8 ±3 ms11.7 ±2 ms-122 μs (-1.0%)NO
    p5012.9 ±3 ms12.5 ±2 ms-361 μs (-2.8%)NO
    p7514.2 ±4 ms13.7 ±2 ms-542 μs (-3.8%)NO
    p9016.0 ±4 ms15.1 ±2 ms-849 μs (-5.3%)NO

    20 test runs in comparison
    CommitTest Runs
    57aaf39
    • 2024-08-08_03:04:49.167217_iUlu
    • 2024-08-08_03:04:49.167274_CDeB
    • 2024-08-08_03:04:49.167286_PHKB
    • 2024-08-08_03:04:49.167295_bXta
    • 2024-08-08_03:04:49.167303_RuUt
    • 2024-08-08_03:04:49.167310_chhd
    • 2024-08-08_03:04:49.167318_CsSw
    • 2024-08-08_03:04:49.167325_EoPm
    • 2024-08-08_03:04:49.167332_ngfa
    • 2024-08-08_03:04:49.167343_naGF
    37167c1
    • 2024-08-08_20:17:30.114375_fVRs
    • 2024-08-08_20:17:30.114420_wajE
    • 2024-08-08_20:17:30.114430_UxUk
    • 2024-08-08_20:17:30.114449_VbrP
    • 2024-08-08_20:17:30.114458_kJvd
    • 2024-08-08_20:17:30.114465_aFkD
    • 2024-08-08_20:17:30.114473_PBAS
    • 2024-08-08_20:17:30.114480_TMLe
    • 2024-08-08_20:17:30.114487_zxHy
    • 2024-08-08_20:17:30.114495_pRqg
    redfin-30
    Percentile57aaf3937167c1DiffSignificant (?)
    p1014.0 ±3 ms14.4 ±8 ms+402 μs (+2.9%)NO
    p2514.6 ±4 ms15.3 ±9 ms+728 μs (+5.0%)NO
    p5015.6 ±4 ms16.5 ±10 ms+860 μs (+5.5%)NO
    p7517.0 ±5 ms17.8 ±11 ms+839 μs (+4.9%)NO
    p9019.6 ±6 ms19.7 ±12 ms+60.7 μs (+0.3%)NO

    20 test runs in comparison
    CommitTest Runs
    57aaf39
    • 2024-08-08_03:04:49.167217_iUlu
    • 2024-08-08_03:04:49.167274_CDeB
    • 2024-08-08_03:04:49.167286_PHKB
    • 2024-08-08_03:04:49.167295_bXta
    • 2024-08-08_03:04:49.167303_RuUt
    • 2024-08-08_03:04:49.167310_chhd
    • 2024-08-08_03:04:49.167318_CsSw
    • 2024-08-08_03:04:49.167325_EoPm
    • 2024-08-08_03:04:49.167332_ngfa
    • 2024-08-08_03:04:49.167343_naGF
    37167c1
    • 2024-08-08_20:17:30.114375_fVRs
    • 2024-08-08_20:17:30.114420_wajE
    • 2024-08-08_20:17:30.114430_UxUk
    • 2024-08-08_20:17:30.114449_VbrP
    • 2024-08-08_20:17:30.114458_kJvd
    • 2024-08-08_20:17:30.114465_aFkD
    • 2024-08-08_20:17:30.114473_PBAS
    • 2024-08-08_20:17:30.114480_TMLe
    • 2024-08-08_20:17:30.114487_zxHy
    • 2024-08-08_20:17:30.114495_pRqg
  • fire-rc

    DeviceStatisticsDistributions
    oriole-32
    Percentile57aaf3937167c1DiffSignificant (?)
    p10146 ±50 μs118 ±49 μs-28.7 μs (-19.6%)NO
    p25155 ±54 μs125 ±53 μs-30.3 μs (-19.5%)NO
    p50177 ±69 μs146 ±70 μs-31.4 μs (-17.7%)NO
    p75214 ±64 μs182 ±83 μs-31.8 μs (-14.9%)NO
    p90279 ±101 μs252 ±126 μs-27.5 μs (-9.8%)NO

    20 test runs in comparison
    CommitTest Runs
    57aaf39
    • 2024-08-08_03:04:49.167217_iUlu
    • 2024-08-08_03:04:49.167274_CDeB
    • 2024-08-08_03:04:49.167286_PHKB
    • 2024-08-08_03:04:49.167295_bXta
    • 2024-08-08_03:04:49.167303_RuUt
    • 2024-08-08_03:04:49.167310_chhd
    • 2024-08-08_03:04:49.167318_CsSw
    • 2024-08-08_03:04:49.167325_EoPm
    • 2024-08-08_03:04:49.167332_ngfa
    • 2024-08-08_03:04:49.167343_naGF
    37167c1
    • 2024-08-08_20:17:30.114375_fVRs
    • 2024-08-08_20:17:30.114420_wajE
    • 2024-08-08_20:17:30.114430_UxUk
    • 2024-08-08_20:17:30.114449_VbrP
    • 2024-08-08_20:17:30.114458_kJvd
    • 2024-08-08_20:17:30.114465_aFkD
    • 2024-08-08_20:17:30.114473_PBAS
    • 2024-08-08_20:17:30.114480_TMLe
    • 2024-08-08_20:17:30.114487_zxHy
    • 2024-08-08_20:17:30.114495_pRqg
    redfin-30
    Percentile57aaf3937167c1DiffSignificant (?)
    p10382 ±326 μs630 ±701 μs+248 μs (+65.0%)NO
    p25460 ±421 μs726 ±834 μs+266 μs (+57.8%)NO
    p50592 ±530 μs856 ±982 μs+264 μs (+44.7%)NO
    p75771 ±716 μs1.01 ±1 ms+234 μs (+30.4%)NO
    p901.06 ±0.9 ms1.23 ±1 ms+178 μs (+16.8%)NO

    20 test runs in comparison
    CommitTest Runs
    57aaf39
    • 2024-08-08_03:04:49.167217_iUlu
    • 2024-08-08_03:04:49.167274_CDeB
    • 2024-08-08_03:04:49.167286_PHKB
    • 2024-08-08_03:04:49.167295_bXta
    • 2024-08-08_03:04:49.167303_RuUt
    • 2024-08-08_03:04:49.167310_chhd
    • 2024-08-08_03:04:49.167318_CsSw
    • 2024-08-08_03:04:49.167325_EoPm
    • 2024-08-08_03:04:49.167332_ngfa
    • 2024-08-08_03:04:49.167343_naGF
    37167c1
    • 2024-08-08_20:17:30.114375_fVRs
    • 2024-08-08_20:17:30.114420_wajE
    • 2024-08-08_20:17:30.114430_UxUk
    • 2024-08-08_20:17:30.114449_VbrP
    • 2024-08-08_20:17:30.114458_kJvd
    • 2024-08-08_20:17:30.114465_aFkD
    • 2024-08-08_20:17:30.114473_PBAS
    • 2024-08-08_20:17:30.114480_TMLe
    • 2024-08-08_20:17:30.114487_zxHy
    • 2024-08-08_20:17:30.114495_pRqg
  • fire-sessions

    DeviceStatisticsDistributions
    oriole-32
    Percentile57aaf3937167c1DiffSignificant (?)
    p102.80 ±0.6 ms2.68 ±0.4 ms-121 μs (-4.3%)NO
    p253.04 ±0.7 ms2.89 ±0.5 ms-154 μs (-5.1%)NO
    p503.48 ±0.8 ms3.30 ±0.6 ms-180 μs (-5.2%)NO
    p754.12 ±1 ms3.90 ±0.6 ms-222 μs (-5.4%)NO
    p905.06 ±1 ms4.74 ±0.8 ms-313 μs (-6.2%)NO

    20 test runs in comparison
    CommitTest Runs
    57aaf39
    • 2024-08-08_03:04:49.167217_iUlu
    • 2024-08-08_03:04:49.167274_CDeB
    • 2024-08-08_03:04:49.167286_PHKB
    • 2024-08-08_03:04:49.167295_bXta
    • 2024-08-08_03:04:49.167303_RuUt
    • 2024-08-08_03:04:49.167310_chhd
    • 2024-08-08_03:04:49.167318_CsSw
    • 2024-08-08_03:04:49.167325_EoPm
    • 2024-08-08_03:04:49.167332_ngfa
    • 2024-08-08_03:04:49.167343_naGF
    37167c1
    • 2024-08-08_20:17:30.114375_fVRs
    • 2024-08-08_20:17:30.114420_wajE
    • 2024-08-08_20:17:30.114430_UxUk
    • 2024-08-08_20:17:30.114449_VbrP
    • 2024-08-08_20:17:30.114458_kJvd
    • 2024-08-08_20:17:30.114465_aFkD
    • 2024-08-08_20:17:30.114473_PBAS
    • 2024-08-08_20:17:30.114480_TMLe
    • 2024-08-08_20:17:30.114487_zxHy
    • 2024-08-08_20:17:30.114495_pRqg
    redfin-30
    Percentile57aaf3937167c1DiffSignificant (?)
    p106.02 ±1 ms5.90 ±0.9 ms-120 μs (-2.0%)NO
    p256.46 ±1 ms6.27 ±0.9 ms-197 μs (-3.0%)NO
    p507.03 ±2 ms6.79 ±1 ms-241 μs (-3.4%)NO
    p757.86 ±3 ms7.49 ±2 ms-371 μs (-4.7%)NO
    p908.89 ±4 ms8.37 ±3 ms-522 μs (-5.9%)NO

    20 test runs in comparison
    CommitTest Runs
    57aaf39
    • 2024-08-08_03:04:49.167217_iUlu
    • 2024-08-08_03:04:49.167274_CDeB
    • 2024-08-08_03:04:49.167286_PHKB
    • 2024-08-08_03:04:49.167295_bXta
    • 2024-08-08_03:04:49.167303_RuUt
    • 2024-08-08_03:04:49.167310_chhd
    • 2024-08-08_03:04:49.167318_CsSw
    • 2024-08-08_03:04:49.167325_EoPm
    • 2024-08-08_03:04:49.167332_ngfa
    • 2024-08-08_03:04:49.167343_naGF
    37167c1
    • 2024-08-08_20:17:30.114375_fVRs
    • 2024-08-08_20:17:30.114420_wajE
    • 2024-08-08_20:17:30.114430_UxUk
    • 2024-08-08_20:17:30.114449_VbrP
    • 2024-08-08_20:17:30.114458_kJvd
    • 2024-08-08_20:17:30.114465_aFkD
    • 2024-08-08_20:17:30.114473_PBAS
    • 2024-08-08_20:17:30.114480_TMLe
    • 2024-08-08_20:17:30.114487_zxHy
    • 2024-08-08_20:17:30.114495_pRqg
  • timeToInitialDisplay

    DeviceStatisticsDistributions
    oriole-32
    Percentile57aaf3937167c1DiffSignificant (?)
    p10197 ±3 ms203 ±3 ms+6.41 ms (+3.3%)NO
    p25202 ±3 ms209 ±5 ms+7.15 ms (+3.5%)NO
    p50209 ±4 ms217 ±6 ms+7.47 ms (+3.6%)NO
    p75218 ±5 ms225 ±7 ms+7.75 ms (+3.6%)NO
    p90226 ±5 ms235 ±6 ms+8.36 ms (+3.7%)NO

    20 test runs in comparison
    CommitTest Runs
    57aaf39
    • 2024-08-08_03:04:49.167217_iUlu
    • 2024-08-08_03:04:49.167274_CDeB
    • 2024-08-08_03:04:49.167286_PHKB
    • 2024-08-08_03:04:49.167295_bXta
    • 2024-08-08_03:04:49.167303_RuUt
    • 2024-08-08_03:04:49.167310_chhd
    • 2024-08-08_03:04:49.167318_CsSw
    • 2024-08-08_03:04:49.167325_EoPm
    • 2024-08-08_03:04:49.167332_ngfa
    • 2024-08-08_03:04:49.167343_naGF
    37167c1
    • 2024-08-08_20:17:30.114375_fVRs
    • 2024-08-08_20:17:30.114420_wajE
    • 2024-08-08_20:17:30.114430_UxUk
    • 2024-08-08_20:17:30.114449_VbrP
    • 2024-08-08_20:17:30.114458_kJvd
    • 2024-08-08_20:17:30.114465_aFkD
    • 2024-08-08_20:17:30.114473_PBAS
    • 2024-08-08_20:17:30.114480_TMLe
    • 2024-08-08_20:17:30.114487_zxHy
    • 2024-08-08_20:17:30.114495_pRqg
    redfin-30
    Percentile57aaf3937167c1DiffSignificant (?)
    p10234 ±4 ms274 ±34 ms+39.8 ms (+17.0%)NO
    p25239 ±5 ms280 ±34 ms+40.3 ms (+16.8%)NO
    p50247 ±4 ms287 ±36 ms+40.7 ms (+16.5%)NO
    p75255 ±5 ms297 ±36 ms+42.6 ms (+16.7%)NO
    p90264 ±5 ms312 ±37 ms+47.5 ms (+18.0%)NO

    20 test runs in comparison
    CommitTest Runs
    57aaf39
    • 2024-08-08_03:04:49.167217_iUlu
    • 2024-08-08_03:04:49.167274_CDeB
    • 2024-08-08_03:04:49.167286_PHKB
    • 2024-08-08_03:04:49.167295_bXta
    • 2024-08-08_03:04:49.167303_RuUt
    • 2024-08-08_03:04:49.167310_chhd
    • 2024-08-08_03:04:49.167318_CsSw
    • 2024-08-08_03:04:49.167325_EoPm
    • 2024-08-08_03:04:49.167332_ngfa
    • 2024-08-08_03:04:49.167343_naGF
    37167c1
    • 2024-08-08_20:17:30.114375_fVRs
    • 2024-08-08_20:17:30.114420_wajE
    • 2024-08-08_20:17:30.114430_UxUk
    • 2024-08-08_20:17:30.114449_VbrP
    • 2024-08-08_20:17:30.114458_kJvd
    • 2024-08-08_20:17:30.114465_aFkD
    • 2024-08-08_20:17:30.114473_PBAS
    • 2024-08-08_20:17:30.114480_TMLe
    • 2024-08-08_20:17:30.114487_zxHy
    • 2024-08-08_20:17:30.114495_pRqg

  1. https://storage.googleapis.com/firebase-sdk-metric-reports/7mBDzFjmPj/index.html

@mrober mrober reopened this Aug 8, 2024
@mrober mrober enabled auto-merge (squash) August 8, 2024 19:41
@mrober
Copy link
Contributor Author

mrober commented Aug 9, 2024

#4345

@mrober mrober merged commit fb2f8b2 into main Aug 12, 2024
42 checks passed
@mrober mrober deleted the crashlytics-sessionId branch August 12, 2024 19:51
@firebase firebase locked and limited conversation to collaborators Sep 13, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants