Skip to content

Change automaticDataCollectionEnabled to default to true. #8999

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

Merged
merged 5 commits into from
May 7, 2025

Conversation

hsubox76
Copy link
Contributor

@hsubox76 hsubox76 commented May 5, 2025

This change should default automaticDataCollectionEnabled to true (it previously defaulted to false).

This value is only consumed by App Check and Vertex.

App Check has been modified so that it retains the previous behavior (that automatic token refresh is off by default and will be turned on if isTokenRefreshEnabled is explicitly set to true). The only unexpected behavior may be that setting isTokenRefreshEnabled will do nothing if automaticDataCollectionEnabled is set to false. This is unlikely to happen as users rarely touch automaticDataCollectionEnabled and this PR defaults it to true. I have added a logged warning just in case, but this is expected to be an edge case.

This affects Vertex in that it allows sending data for AI monitoring by default.

Copy link

changeset-bot bot commented May 5, 2025

🦋 Changeset detected

Latest commit: 32e9eef

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 5 packages
Name Type
@firebase/app-check Minor
@firebase/app Minor
@firebase/app-compat Minor
firebase Minor
@firebase/app-check-compat Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

Copy link
Contributor

github-actions bot commented May 5, 2025

Vertex AI Mock Responses Check ⚠️

A newer major version of the mock responses for Vertex AI unit tests is available. update_vertexai_responses.sh should be updated to clone the latest version of the responses: v11.1

Copy link
Contributor

github-actions bot commented May 5, 2025

Changeset File Check ✅

  • No modified packages are missing from the changeset file.
  • No changeset formatting errors detected.

@google-oss-bot
Copy link
Contributor

google-oss-bot commented May 5, 2025

Size Report 1

Affected Products

  • @firebase/app

    TypeBase (080a90d)Merge (095d91f)Diff
    browser19.5 kB19.5 kB-3 B (-0.0%)
    main20.4 kB20.4 kB-3 B (-0.0%)
    module19.5 kB19.5 kB-3 B (-0.0%)
  • @firebase/app-check

    TypeBase (080a90d)Merge (095d91f)Diff
    browser26.7 kB26.9 kB+210 B (+0.8%)
    main27.7 kB27.9 kB+210 B (+0.8%)
    module26.7 kB26.9 kB+210 B (+0.8%)
  • @firebase/auth

    TypeBase (080a90d)Merge (095d91f)Diff
    browser193 kB193 kB+2 B (+0.0%)
    cordova166 kB166 kB+2 B (+0.0%)
    main147 kB147 kB+2 B (+0.0%)
    module193 kB193 kB+2 B (+0.0%)
    react-native165 kB165 kB+2 B (+0.0%)
  • @firebase/auth-cordova

    TypeBase (080a90d)Merge (095d91f)Diff
    browser166 kB166 kB+2 B (+0.0%)
    module166 kB166 kB+2 B (+0.0%)
  • @firebase/auth-web-extension

    TypeBase (080a90d)Merge (095d91f)Diff
    browser142 kB142 kB+2 B (+0.0%)
    main159 kB159 kB+2 B (+0.0%)
    module142 kB142 kB+2 B (+0.0%)
  • @firebase/auth/internal

    TypeBase (080a90d)Merge (095d91f)Diff
    browser204 kB204 kB+2 B (+0.0%)
    main174 kB174 kB+2 B (+0.0%)
    module204 kB204 kB+2 B (+0.0%)
  • @firebase/database-compat/standalone

    TypeBase (080a90d)Merge (095d91f)Diff
    main366 kB366 kB-3 B (-0.0%)
  • bundle

    46 size changes

    TypeBase (080a90d)Merge (095d91f)Diff
    analytics (logEvent)44.7 kB44.7 kB-1 B (-0.0%)
    app-check (CustomProvider)37.8 kB38.0 kB+203 B (+0.5%)
    app-check (ReCaptchaEnterpriseProvider)40.3 kB40.5 kB+203 B (+0.5%)
    app-check (ReCaptchaV3Provider)40.3 kB40.5 kB+203 B (+0.5%)
    auth (Anonymous)77.8 kB77.8 kB-1 B (-0.0%)
    auth (EmailAndPassword)87.9 kB87.9 kB-1 B (-0.0%)
    auth (GoogleFBTwitterGitHubPopup)105 kB105 kB-2 B (-0.0%)
    auth (GooglePopup)102 kB102 kB-1 B (-0.0%)
    auth (GoogleRedirect)102 kB102 kB-1 B (-0.0%)
    auth (Phone)95.3 kB95.3 kB-1 B (-0.0%)
    database (Append to a list of data)150 kB150 kB-1 B (-0.0%)
    database (Filtering data)149 kB149 kB-1 B (-0.0%)
    database (Listen for child events)165 kB165 kB-1 B (-0.0%)
    database (Listen for value events + Detach listeners)165 kB165 kB-1 B (-0.0%)
    database (Listen for value events)165 kB165 kB-1 B (-0.0%)
    database (Read data once)165 kB165 kB-1 B (-0.0%)
    database (Save data as transactions)167 kB167 kB-1 B (-0.0%)
    database (Sort data)151 kB151 kB-1 B (-0.0%)
    database (Write data)149 kB149 kB-1 B (-0.0%)
    firestore (CSI Auto Indexing Disable and Delete)275 kB275 kB-1 B (-0.0%)
    firestore (CSI Auto Indexing Enable)275 kB275 kB-1 B (-0.0%)
    firestore (Persistence)306 kB306 kB-1 B (-0.0%)
    firestore (Query Cursors)252 kB252 kB-1 B (-0.0%)
    firestore (Query)249 kB249 kB-1 B (-0.0%)
    firestore (Read data once)237 kB237 kB-1 B (-0.0%)
    firestore (Read Write w Persistence)331 kB331 kB-1 B (-0.0%)
    firestore (Realtime updates)239 kB239 kB-1 B (-0.0%)
    firestore (Transaction)216 kB216 kB-1 B (-0.0%)
    firestore (Write data)216 kB216 kB-1 B (-0.0%)
    firestore-lite (Query Cursors)105 kB105 kB-1 B (-0.0%)
    firestore-lite (Query)101 kB101 kB-1 B (-0.0%)
    firestore-lite (Read data once)76.3 kB76.3 kB-1 B (-0.0%)
    firestore-lite (Transaction)102 kB102 kB-1 B (-0.0%)
    firestore-lite (Write data)85.9 kB85.9 kB-1 B (-0.0%)
    functions (call)35.0 kB35.0 kB-1 B (-0.0%)
    messaging (send + receive)47.5 kB47.5 kB-1 B (-0.0%)
    performance (trace)62.4 kB62.4 kB-1 B (-0.0%)
    remote-config (getAndFetch)48.8 kB48.8 kB-1 B (-0.0%)
    storage (getBytes)42.8 kB42.8 kB-1 B (-0.0%)
    storage (getDownloadURL)44.9 kB44.9 kB-1 B (-0.0%)
    storage (getMetadata)44.3 kB44.3 kB-1 B (-0.0%)
    storage (list + listAll)43.8 kB43.8 kB-1 B (-0.0%)
    storage (updateMetadata)44.6 kB44.6 kB-1 B (-0.0%)
    storage (uploadBytes)49.5 kB49.5 kB-1 B (-0.0%)
    storage (uploadBytesResumable)59.4 kB59.4 kB-1 B (-0.0%)
    storage (uploadString)49.7 kB49.7 kB-1 B (-0.0%)

  • firebase

    TypeBase (080a90d)Merge (095d91f)Diff
    firebase-app-check-compat.js22.9 kB23.1 kB+197 B (+0.9%)
    firebase-app-check.js25.3 kB25.5 kB+194 B (+0.8%)
    firebase-app.js103 kB103 kB-3 B (-0.0%)
    firebase-auth-compat.js141 kB141 kB+1 B (+0.0%)
    firebase-auth-cordova.js138 kB138 kB+3 B (+0.0%)
    firebase-auth-web-extension.js121 kB121 kB+3 B (+0.0%)
    firebase-auth.js158 kB158 kB+3 B (+0.0%)
    firebase-compat.js797 kB798 kB+199 B (+0.0%)

Test Logs

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

@google-oss-bot
Copy link
Contributor

google-oss-bot commented May 5, 2025

Size Analysis Report 1

Affected Products

  • @firebase/analytics

    • getAnalytics

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps44.6 kB44.6 kB-1 B (-0.0%)
  • @firebase/app

    • getApp

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size10.2 kB10.2 kB-1 B (-0.0%)
      size-with-ext-deps25.2 kB25.2 kB-1 B (-0.0%)
    • initializeApp

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size10.1 kB10.1 kB-1 B (-0.0%)
      size-with-ext-deps25.1 kB25.1 kB-1 B (-0.0%)
    • initializeServerApp

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size12.3 kB12.3 kB-2 B (-0.0%)
      size-with-ext-deps26.3 kB26.3 kB-2 B (-0.0%)
  • @firebase/app-check

    • initializeAppCheck

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size11.5 kB11.7 kB+203 B (+1.8%)
      size-with-ext-deps36.8 kB37.0 kB+203 B (+0.6%)
  • @firebase/auth

    • connectAuthEmulator

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size42.3 kB42.3 kB-1 B (-0.0%)
      size-with-ext-deps64.8 kB64.8 kB-1 B (-0.0%)
    • getAuth

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size75.4 kB75.4 kB-1 B (-0.0%)
      size-with-ext-deps104 kB104 kB-2 B (-0.0%)
  • @firebase/data-connect

    • getDataConnect

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps38.8 kB38.8 kB-1 B (-0.0%)
    • subscribe

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps39.3 kB39.3 kB-1 B (-0.0%)
    • toQueryRef

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps39.0 kB39.0 kB-1 B (-0.0%)
    • validateArgs

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps38.9 kB38.9 kB-1 B (-0.0%)
  • @firebase/database

    • getDatabase

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps148 kB148 kB-1 B (-0.0%)
  • @firebase/firestore

    • getFirestore

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps96.5 kB96.5 kB-1 B (-0.0%)
  • @firebase/functions

    • getFunctions

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps28.8 kB28.8 kB-1 B (-0.0%)
  • @firebase/installations

    • getInstallations

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps34.0 kB34.0 kB-1 B (-0.0%)
  • @firebase/messaging

    • getMessaging

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps47.2 kB47.2 kB-1 B (-0.0%)
  • @firebase/performance

    • getPerformance

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps62.3 kB62.3 kB-1 B (-0.0%)
  • @firebase/remote-config

    • getRemoteConfig

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps46.6 kB46.6 kB-1 B (-0.0%)
  • @firebase/storage

    • getStorage

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps38.4 kB38.4 kB-1 B (-0.0%)
  • @firebase/vertexai

    • getVertexAI

      Size

      TypeBase (080a90d)Merge (095d91f)Diff
      size-with-ext-deps28.8 kB28.8 kB-1 B (-0.0%)

Test Logs

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

@hsubox76 hsubox76 marked this pull request as ready for review May 6, 2025 17:29
@hsubox76 hsubox76 requested review from a team as code owners May 6, 2025 17:29
@hsubox76 hsubox76 requested a review from a team as a code owner May 6, 2025 20:34
Copy link
Contributor

@egilmorez egilmorez left a comment

Choose a reason for hiding this comment

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

LGTM!

@hsubox76 hsubox76 merged commit 3789b5a into main May 7, 2025
42 of 49 checks passed
@hsubox76 hsubox76 deleted the ch-data-toggle branch May 7, 2025 14:57
@google-oss-bot google-oss-bot mentioned this pull request May 7, 2025
hsubox76 added a commit that referenced this pull request May 7, 2025
hsubox76 added a commit that referenced this pull request May 7, 2025
@hsubox76 hsubox76 mentioned this pull request May 7, 2025
hsubox76 added a commit that referenced this pull request May 7, 2025
* Revert "Change automaticDataCollectionEnabled to default to true. (#8999)"

This reverts commit 3789b5a.

* Revert #8999 - backend is not ready
@google-oss-bot google-oss-bot mentioned this pull request May 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants