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

Use AQS provided sessionId for Fireperf events. #5060

Merged
merged 5 commits into from
Jun 12, 2023

Conversation

visumickey
Copy link
Contributor

No description provided.

@google-oss-bot
Copy link
Contributor

google-oss-bot commented Jun 7, 2023

Coverage Report 1

Affected Products

  • firebase-perf

    Overall coverage changed from ? (ef89334) to 71.14% (641d844) by ?.

    103 individual files with coverage change

    FilenameBase (ef89334)Merge (641d844)Diff
    AddTrace.java?0.00%?
    AndroidApplicationInfo.java?34.71%?
    AndroidApplicationInfoOrBuilder.java?0.00%?
    AndroidLogger.java?100.00%?
    AndroidMemoryReading.java?38.36%?
    AndroidMemoryReadingOrBuilder.java?0.00%?
    ApplicationInfo.java?45.00%?
    ApplicationInfoOrBuilder.java?0.00%?
    ApplicationProcessState.java?73.91%?
    AppStartTrace.java?77.37%?
    AppStateMonitor.java?84.97%?
    AppStateUpdateHandler.java?89.29%?
    Clock.java?100.00%?
    ConfigResolver.java?93.19%?
    ConfigurationConstants.java?97.86%?
    ConfigurationFlag.java?100.00%?
    ConsoleUrlGenerator.java?37.50%?
    Constants.java?95.65%?
    Counter.java?90.91%?
    CpuGaugeCollector.java?92.77%?
    CpuMetricReading.java?39.33%?
    CpuMetricReadingOrBuilder.java?0.00%?
    DaggerFirebasePerformanceComponent.java?100.00%?
    DeviceCacheManager.java?76.42%?
    FirebasePerfApplicationInfoValidator.java?92.86%?
    FirebasePerfEarly.java?85.00%?
    FirebasePerfGaugeMetricValidator.java?100.00%?
    FirebasePerfHttpClient.java?93.85%?
    FirebasePerfMetricProto.java?0.00%?
    FirebasePerfNetworkValidator.java?86.67%?
    FirebasePerfOkHttpClient.java?44.90%?
    FirebasePerformance.java?79.12%?
    FirebasePerformanceAttributable.java?0.00%?
    FirebasePerformanceComponent.java?0.00%?
    FirebasePerformanceInitializer.java?33.33%?
    FirebasePerformanceModule.java?100.00%?
    FirebasePerformanceModule_ProvidesConfigResolverFactory.java?100.00%?
    FirebasePerformanceModule_ProvidesFirebaseAppFactory.java?100.00%?
    FirebasePerformanceModule_ProvidesFirebaseInstallationsFactory.java?100.00%?
    FirebasePerformanceModule_ProvidesRemoteConfigComponentFactory.java?100.00%?
    FirebasePerformanceModule_ProvidesRemoteConfigManagerFactory.java?100.00%?
    FirebasePerformanceModule_ProvidesSessionManagerFactory.java?100.00%?
    FirebasePerformanceModule_ProvidesTransportFactoryProviderFactory.java?100.00%?
    FirebasePerformance_Factory.java?100.00%?
    FirebasePerfRegistrar.java?100.00%?
    FirebasePerfTraceValidator.java?85.87%?
    FirebasePerfUrlConnection.java?44.26%?
    FirstDrawDoneListener.java?85.71%?
    FlgTransport.java?83.33%?
    FragmentStateMonitor.java?94.87%?
    FrameMetricsCalculator.java?96.77%?
    FrameMetricsRecorder.java?76.32%?
    GaugeManager.java?98.40%?
    GaugeMetadata.java?26.17%?
    GaugeMetadataManager.java?77.78%?
    GaugeMetadataOrBuilder.java?0.00%?
    GaugeMetric.java?39.47%?
    GaugeMetricOrBuilder.java?0.00%?
    HttpMetric.java?92.65%?
    ImmutableBundle.java?100.00%?
    InstrHttpInputStream.java?92.86%?
    InstrHttpOutputStream.java?98.00%?
    InstrHttpsURLConnection.java?94.32%?
    InstrHttpURLConnection.java?93.42%?
    InstrumentApacheHttpResponseHandler.java?100.00%?
    InstrumentOkHttpEnqueueCallback.java?100.00%?
    InstrURLConnectionBase.java?94.86%?
    LogWrapper.java?23.08%?
    MemoryGaugeCollector.java?91.38%?
    NetworkConnectionInfo.java?0.00%?
    NetworkConnectionInfoOrBuilder.java?0.00%?
    NetworkRequestMetric.java?49.16%?
    NetworkRequestMetricBuilder.java?95.97%?
    NetworkRequestMetricBuilderUtil.java?75.00%?
    NetworkRequestMetricOrBuilder.java?0.00%?
    Optional.java?86.67%?
    PendingPerfEvent.java?100.00%?
    PerfMetric.java?33.67%?
    PerfMetricOrBuilder.java?0.00%?
    PerfMetricValidator.java?93.55%?
    PerfSession.java?93.22%?
    PerfSessionOrBuilder.java?0.00%?
    PreDrawListener.java?94.12%?
    Rate.java?100.00%?
    RateLimiter.java?91.54%?
    RemoteConfigManager.java?91.30%?
    ResourceType.java?0.00%?
    ScreenTraceUtil.java?94.12%?
    SessionAwareObject.java?0.00%?
    SessionManager.java?100.00%?
    SessionVerbosity.java?68.42%?
    StorageUnit.java?57.89%?
    Timer.java?90.63%?
    Trace.java?95.83%?
    TraceMetric.java?43.14%?
    TraceMetricBuilder.java?100.00%?
    TraceMetricOrBuilder.java?0.00%?
    TransportInfo.java?0.00%?
    TransportInfoOrBuilder.java?0.00%?
    TransportManager.java?94.88%?
    URLAllowlist.java?94.44%?
    URLWrapper.java?0.00%?
    Utils.java?78.57%?

Test Logs

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

@github-actions
Copy link
Contributor

github-actions bot commented Jun 7, 2023

Unit Test Results

   102 files     102 suites   7m 16s ⏱️
   958 tests    958 ✔️ 0 💤 0
1 916 runs  1 916 ✔️ 0 💤 0

Results for commit 737074e.

♻️ This comment has been updated with latest results.

@google-oss-bot
Copy link
Contributor

google-oss-bot commented Jun 7, 2023

Size Report 1

Affected Products

  • base

    TypeBase (ef89334)Merge (641d844)Diff
    apk (aggressive)?8.39 kB? (?)
    apk (release)?8.65 kB? (?)
  • firebase-perf

    TypeBase (ef89334)Merge (641d844)Diff
    aar?317 kB? (?)
  • firebase-sessions

    TypeBase (ef89334)Merge (641d844)Diff
    aar?114 kB? (?)

Test Logs

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

@visumickey
Copy link
Contributor Author

/retest

Copy link
Contributor

@samedson samedson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@visumickey visumickey merged commit c210c81 into firebase-sessions Jun 12, 2023
@visumickey visumickey deleted the firebase-sessions-perf-usesessioninfo branch June 12, 2023 18:17
mrober added a commit that referenced this pull request Jun 26, 2023
* Initial commit for Firebase Sessions SDK (#4713)

* Initial commit for Firebase Sessions SDK

* Add copyright notice

* Remove redundant dependency

* Revert 'Remove redundant dependency' to avoid using api

* Generate api.txt file

* Implement SessionInitiator and hook it up to lifecycle events (#4723)

* Implement SessionInitiator and hook it up to lifecycle events

* Add a warning when failed to register lifecycle callbacks

* Fix formatting

* Use kotlin.time.Duration instead of Long for time intervals (#4733)

* Use kotlin.time.Duration instead of Long for time intervals

* Adjust test constants

* Simplify elapsedRealtime to always be millis precision

* Add SessionGenerator to generate the Session ID (#4747)

* Add SessionEvent data class (#4763)

* Add SessionEvent data class

* Add enum test case

* Remove serialization (this will be handled in encoders) and rename SessionState

* Generate a SessionEvent based on the SessionState

* Rename SessionState to SessionDetails

* Firebase Session Event

* Add Firebase Sessions Test App (#4775)

* Add Firebase Sessions Test App

* Remove boilerplate

* Add JSON encoder for SessionEvents (#4778)

* Use the private setter pattern on SessionGenerator.currentSession (#4785)

* Use the private setter pattern on SessionGenerator.currentSession

* Comments

* Integrate with FirebaseInstallations. (#4796)

* Populate firebaseInstallationId field in session (#4801)

* Package session start event's application information. (#4829)

* Fix workflows for Firebase Sessions (#4841)

* Use googleServices.gradle

* Move package level function to object to fix api surface check

* Add android manifest file with versionName set to fix android tests

* Update pinned deps

* Make getApplicationInfo look leaner

* Setup configuration layer for the library. (#4853)

* Fix Firebase Sessions test app temporarily (#4858)

* Add GDT to Firebase Sessions (#4851)

* Add README files (#4857)

* Fix test app and add README's

* Undo app changes

* Undo app changes

* Add description and formatting to README file

* Add google-services.json file to unit tests (#4868)

* Setup sessions e2e workflow (#4859)

* Start setting up sessions e2e workflow

* Remove schedule

* Format

* Setup gcloud

* Set FIREBASE_APP_CHECK_DEBUG_SECRET

* Set FTL_RESULTS_BUCKET

* Add schedule

* Add 20 min

* Implement local manifest override configs (#4877)

* Fix encoding for Session Events (#4870)

* Use test app for Sessions e2e test (#4881)

* Use test app for Sessions e2e test

* Add test lab plugin

* Use firebase-sessions branch

* Increase time to log session to 60 seconds

* Move currentTimeUs into WallClock (#4890)

* Populate sampling rate in session event (#4891)

* Populate sampling rate in session event

* Fix test

* Fix merge

* Add TimeProvider interface to abstract away the clock (#4905)

* Add TimeProvider interface to abstract away the clock

* Add comment about default elapsed time being zero

* Fill in device_model field for AQS (#4892)

* Implement sampling (#4896)

* Implement sampling

* return

* Remove collectEvents from SessionDetails, use sessionGenerator.collectEvents

* Don't generate whole Session Start event for sampled event

* Fix log message

* Add Sessions to benchmark config (#4914)

* Introduce remote config cache for storing configs fetched remotely. (#4917)

* Make logging consistent with Apple SDK (#4919)

* Pass a CoroutineContext, not CoroutineDispatcher, to SessionCoordinator (#4950)

* Implement remote config fetcher to fetch and cache configs. (#4967)

* Add os_version, app_build_version, device_manufacturer for Sessions #11222 (#4984)

* Add App information for config fetching. (#4992)

* Update the header params for network request. (#4995)

* Add thread safe FirebaseSessionsDependencies (#4983)

* Add thread safe FirebaseSessionsDependencies

* Remove debug line

* Format

* Address comments

* Rename to getRegisteredSubscribers

* Add register api to FirebaseSessions so products can integrate (#4989)

* Add thread safe FirebaseSessionsDependencies

* Remove debug line

* Format

* Add register api to FirebaseSessions so products can integrate

* Fix Android tests and api txt file

* Address comments

* Address comments

* Rename to getRegisteredSubscribers

* Fix callsite

* Add Sessions to Crashlytics (#4993)

* Add thread safe FirebaseSessionsDependencies

* Remove debug line

* Format

* Add register api to FirebaseSessions so products can integrate

* Fix Android tests and api txt file

* Add Sessions to Crashlytics

* Address comments

* Address comments

* Rename to getRegisteredSubscribers

* Fix callsite

* Add todo

* Fix gradle command in README

* Use firebase-encoders-processor instead of manually building encoder (#5030)

* Fix behaviour with multiple subscribers (#5031)

* Fix behaviour with multiple subscribers

* Fix format

* Integrate Firebase Performance with Firebase Sessions. (#5020)

* Clean up how we launch suspend functions (#5028)

* Make `initiateSessionStart` a suspend function

* Notify subscribers regardless of sampling and data collection state

* Add timestamp to SessionDetails

* Fix format

* Generate the session details on main thread

* Fix tests

* Call it sessionStartTimestampUs for clarity sake

* Add and populate appQualitySessionId in Crashlytics reports (#5045)

* Add and populate appQualitySessionId in Crashlytics reports

* Bump Crashlytics ktx target sdk to 33, same as Java sdk

* Log warning when missing AQS session id

* Pin firebase-datatransport version (#5070)

* Use AQS provided sessionId for Fireperf events. (#5060)

* Fix firebase-crashlytics-ktx instrumented tests (#5068)

* Fix firebase-crashlytics-ktx deps

* Fix CrashlyticsTests and clean up build file

* Make FirebaseCrashlyticsKtxRegistrar internal

* Bump health metrics compile sdk

* Add versionName version

* Add check if Sessions is disabled (#5061)

* Do not send session id to subscribers if Sessions is disabled

* Move the Sessions settings disabled check to after subscrubers

* Add fid to Crashlytics report (#5052)

* Add fid to Crashlytics report

* Format

* Handle IOExceptions when fetching remote settings (#5092)

* Handle IOExceptions went fetching remote settings

* Add failure test case for RemoteSettingsFetcher

* Make remote settings fetch non-blocking (#5095)

* Ensure the settings cache has loaded from disk before reading any values (#5103)

* Make remote settings fetch non-blocking

* Ensure the settings cache has loaded from disk before reading any values

* Fix runtime exception with a load-bearing empty block

* Inline the definition of metadata to avoid needing an empty block

* Comments

* Fetch remote settings on session, not on launch (#5107)

* Make remote settings fetch non-blocking

* Ensure the settings cache has loaded from disk before reading any values

* Fix runtime exception with a load-bearing empty block

* Inline the definition of metadata to avoid needing an empty block

* Fetch remote settings on session, not on launch

* Log warning when we fail to fetch the fid

---------

Co-authored-by: Sam Edson <samedson@google.com>
Co-authored-by: Visu <visumickey@gmail.com>
@firebase firebase locked and limited conversation to collaborators Jul 13, 2023
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.

4 participants