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

Emulator Idempotency: Firestore #8780

Merged
merged 8 commits into from
Feb 11, 2025
Merged

Conversation

DellaBitta
Copy link
Contributor

@DellaBitta DellaBitta commented Feb 9, 2025

Discussion

Update connectFirestoreEmulator to support its invocation more than once. If the Firestore instance is already in use, and connectFirestoreEmulator is invoked with the same configuration, then the invocation will now succeed instead of assert.

The implementation takes the Data Connect implementation as inspiration. Data Connect stores the parameters passed to connectDataConnectEmulator on the instance of Data Connect itself, so that they can be quickly checked to see if subsequent invocations match. This PR implements a similar storage and compare process with the optional emulatorOptions parameter (host and port are already stored).

This PR unlocks support for SSR frameworks which render the page numerous times with the same instances of Firestore. Before this PR customers were required to guard against calling connectFirestoreEmulator in their SSR logic, which added to code complexity. Now the Firebase SDK does that guarding logic so that our users' apps don't have to.

Testing

CI, new tests added to packages/firestore/test/integration/api/validation.test.ts and packages/firestore/test/unit/api/database.test.ts.

API Changes

N/A

Copy link
Contributor

github-actions bot commented Feb 9, 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: v6.1

Copy link

changeset-bot bot commented Feb 10, 2025

⚠️ No Changeset found

Latest commit: de0b1e3

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

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

@DellaBitta DellaBitta changed the title Ddb firestore emulator reconnect Emulator Idempotency: Firestore Feb 10, 2025
@google-oss-bot
Copy link
Contributor

google-oss-bot commented Feb 10, 2025

Size Report 1

Affected Products

  • @firebase/firestore

    TypeBase (4e6a5c6)Merge (243afc0)Diff
    browser381 kB381 kB+246 B (+0.1%)
    main589 kB590 kB+342 B (+0.1%)
    module381 kB381 kB+246 B (+0.1%)
    react-native381 kB381 kB+246 B (+0.1%)
  • @firebase/firestore-lite

    TypeBase (4e6a5c6)Merge (243afc0)Diff
    browser112 kB112 kB+246 B (+0.2%)
    main154 kB155 kB+342 B (+0.2%)
    module112 kB112 kB+246 B (+0.2%)
    react-native112 kB113 kB+246 B (+0.2%)
  • bundle

    15 size changes

    TypeBase (4e6a5c6)Merge (243afc0)Diff
    firestore (CSI Auto Indexing Disable and Delete)271 kB272 kB+238 B (+0.1%)
    firestore (CSI Auto Indexing Enable)271 kB272 kB+238 B (+0.1%)
    firestore (Persistence)303 kB303 kB+238 B (+0.1%)
    firestore (Query Cursors)250 kB250 kB+238 B (+0.1%)
    firestore (Query)247 kB247 kB+238 B (+0.1%)
    firestore (Read data once)235 kB235 kB+238 B (+0.1%)
    firestore (Read Write w Persistence)327 kB327 kB+238 B (+0.1%)
    firestore (Realtime updates)237 kB238 kB+238 B (+0.1%)
    firestore (Transaction)214 kB215 kB+238 B (+0.1%)
    firestore (Write data)214 kB214 kB+238 B (+0.1%)
    firestore-lite (Query Cursors)103 kB103 kB+238 B (+0.2%)
    firestore-lite (Query)99.4 kB99.6 kB+238 B (+0.2%)
    firestore-lite (Read data once)74.8 kB75.1 kB+238 B (+0.3%)
    firestore-lite (Transaction)100 kB100 kB+238 B (+0.2%)
    firestore-lite (Write data)84.4 kB84.7 kB+238 B (+0.3%)

  • firebase

    TypeBase (4e6a5c6)Merge (243afc0)Diff
    firebase-compat.js791 kB792 kB+237 B (+0.0%)
    firebase-firestore-compat.js339 kB339 kB+236 B (+0.1%)
    firebase-firestore-lite.js131 kB131 kB+246 B (+0.2%)
    firebase-firestore.js439 kB439 kB+246 B (+0.1%)

Test Logs

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

@google-oss-bot
Copy link
Contributor

google-oss-bot commented Feb 10, 2025

Size Analysis Report 1

Affected Products

  • @firebase/firestore

    • AbstractUserDataWriter

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size24.8 kB24.9 kB+120 B (+0.5%)
      size-with-ext-deps94.9 kB95.0 kB+120 B (+0.1%)
    • AggregateField

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.4 kB15.5 kB+120 B (+0.8%)
      size-with-ext-deps85.5 kB85.6 kB+120 B (+0.1%)
    • AggregateQuerySnapshot

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.5 kB15.6 kB+120 B (+0.8%)
      size-with-ext-deps85.6 kB85.7 kB+120 B (+0.1%)
    • Bytes

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size16.9 kB17.0 kB+120 B (+0.7%)
      size-with-ext-deps86.9 kB87.1 kB+120 B (+0.1%)
    • CACHE_SIZE_UNLIMITED

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.3 kB15.5 kB+120 B (+0.8%)
      size-with-ext-deps85.4 kB85.5 kB+120 B (+0.1%)
    • CollectionReference

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size19.5 kB19.7 kB+120 B (+0.6%)
      size-with-ext-deps89.7 kB89.8 kB+120 B (+0.1%)
    • DocumentReference

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size19.5 kB19.7 kB+120 B (+0.6%)
      size-with-ext-deps89.7 kB89.8 kB+120 B (+0.1%)
    • DocumentSnapshot

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size23.0 kB23.2 kB+120 B (+0.5%)
      size-with-ext-deps93.2 kB93.3 kB+120 B (+0.1%)
    • FieldPath

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size18.5 kB18.7 kB+120 B (+0.6%)
      size-with-ext-deps88.7 kB88.8 kB+120 B (+0.1%)
    • FieldValue

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.4 kB15.5 kB+120 B (+0.8%)
      size-with-ext-deps85.4 kB85.6 kB+120 B (+0.1%)
    • Firestore

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.3 kB15.4 kB+120 B (+0.8%)
      size-with-ext-deps85.4 kB85.5 kB+120 B (+0.1%)
    • FirestoreError

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.3 kB15.4 kB+120 B (+0.8%)
      size-with-ext-deps85.4 kB85.5 kB+120 B (+0.1%)
    • GeoPoint

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.9 kB16.0 kB+120 B (+0.8%)
      size-with-ext-deps86.0 kB86.1 kB+120 B (+0.1%)
    • LoadBundleTask

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size16.2 kB16.3 kB+120 B (+0.7%)
      size-with-ext-deps86.3 kB86.4 kB+120 B (+0.1%)
    • PersistentCacheIndexManager

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.4 kB15.5 kB+120 B (+0.8%)
      size-with-ext-deps85.5 kB85.6 kB+120 B (+0.1%)
    • Query

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.5 kB15.6 kB+120 B (+0.8%)
      size-with-ext-deps85.5 kB85.7 kB+120 B (+0.1%)
    • QueryCompositeFilterConstraint

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size17.6 kB17.7 kB+120 B (+0.7%)
      size-with-ext-deps87.7 kB87.8 kB+120 B (+0.1%)
    • QueryConstraint

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.3 kB15.5 kB+120 B (+0.8%)
      size-with-ext-deps85.4 kB85.5 kB+120 B (+0.1%)
    • QueryDocumentSnapshot

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size23.0 kB23.2 kB+120 B (+0.5%)
      size-with-ext-deps93.2 kB93.3 kB+120 B (+0.1%)
    • QueryEndAtConstraint

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size42.2 kB42.3 kB+120 B (+0.3%)
      size-with-ext-deps112 kB113 kB+120 B (+0.1%)
    • QueryFieldFilterConstraint

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size40.7 kB40.8 kB+120 B (+0.3%)
      size-with-ext-deps111 kB111 kB+120 B (+0.1%)
    • QueryLimitConstraint

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size16.1 kB16.2 kB+120 B (+0.7%)
      size-with-ext-deps86.2 kB86.3 kB+120 B (+0.1%)
    • QueryOrderByConstraint

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size16.5 kB16.7 kB+120 B (+0.7%)
      size-with-ext-deps86.6 kB86.8 kB+120 B (+0.1%)
    • QuerySnapshot

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size25.0 kB25.1 kB+120 B (+0.5%)
      size-with-ext-deps95.1 kB95.2 kB+120 B (+0.1%)
    • QueryStartAtConstraint

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size42.2 kB42.3 kB+120 B (+0.3%)
      size-with-ext-deps112 kB113 kB+120 B (+0.1%)
    • SnapshotMetadata

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.5 kB15.6 kB+120 B (+0.8%)
      size-with-ext-deps85.6 kB85.7 kB+120 B (+0.1%)
    • Timestamp

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size16.5 kB16.6 kB+120 B (+0.7%)
      size-with-ext-deps86.6 kB86.7 kB+120 B (+0.1%)
    • Transaction

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size50.8 kB51.0 kB+120 B (+0.2%)
      size-with-ext-deps121 kB121 kB+120 B (+0.1%)
    • VectorValue

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.6 kB15.7 kB+120 B (+0.8%)
      size-with-ext-deps85.6 kB85.8 kB+120 B (+0.1%)
    • WriteBatch

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size47.3 kB47.5 kB+120 B (+0.3%)
      size-with-ext-deps118 kB118 kB+120 B (+0.1%)
    • _AutoId

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.8 kB15.9 kB+120 B (+0.8%)
      size-with-ext-deps85.9 kB86.0 kB+120 B (+0.1%)
    • _ByteString

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size16.4 kB16.5 kB+120 B (+0.7%)
      size-with-ext-deps86.5 kB86.6 kB+120 B (+0.1%)
    • _DatabaseId

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.3 kB15.4 kB+120 B (+0.8%)
      size-with-ext-deps85.4 kB85.5 kB+120 B (+0.1%)
    • _DocumentKey

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size25.2 kB25.3 kB+120 B (+0.5%)
      size-with-ext-deps95.3 kB95.4 kB+120 B (+0.1%)
    • _EmptyAppCheckTokenProvider

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.4 kB15.6 kB+120 B (+0.8%)
      size-with-ext-deps85.5 kB85.6 kB+120 B (+0.1%)
    • _EmptyAuthCredentialsProvider

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.3 kB15.5 kB+120 B (+0.8%)
      size-with-ext-deps85.4 kB85.5 kB+120 B (+0.1%)
    • _FieldPath

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size18.3 kB18.4 kB+120 B (+0.7%)
      size-with-ext-deps88.4 kB88.5 kB+120 B (+0.1%)
    • _TestingHooks

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.8 kB15.9 kB+120 B (+0.8%)
      size-with-ext-deps85.9 kB86.0 kB+120 B (+0.1%)
    • _cast

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size16.1 kB16.2 kB+120 B (+0.7%)
      size-with-ext-deps86.2 kB86.3 kB+120 B (+0.1%)
    • _debugAssert

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.3 kB15.5 kB+120 B (+0.8%)
      size-with-ext-deps85.4 kB85.5 kB+120 B (+0.1%)
    • _internalAggregationQueryToProtoRunAggregationQueryRequest

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size36.8 kB36.9 kB+120 B (+0.3%)
      size-with-ext-deps107 kB107 kB+120 B (+0.1%)
    • _internalQueryToProtoQueryTarget

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size44.5 kB44.6 kB+120 B (+0.3%)
      size-with-ext-deps115 kB115 kB+120 B (+0.1%)
    • _isBase64Available

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.4 kB15.5 kB+120 B (+0.8%)
      size-with-ext-deps85.4 kB85.6 kB+120 B (+0.1%)
    • _logWarn

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.4 kB15.5 kB+120 B (+0.8%)
      size-with-ext-deps85.5 kB85.6 kB+120 B (+0.1%)
    • _validateIsNotUsedTogether

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.3 kB15.5 kB+120 B (+0.8%)
      size-with-ext-deps85.4 kB85.5 kB+120 B (+0.1%)
    • addDoc

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size133 kB133 kB+120 B (+0.1%)
      size-with-ext-deps205 kB205 kB+120 B (+0.1%)
    • aggregateFieldEqual

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.7 kB15.8 kB+120 B (+0.8%)
      size-with-ext-deps85.8 kB85.9 kB+120 B (+0.1%)
    • aggregateQuerySnapshotEqual

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size39.5 kB39.6 kB+120 B (+0.3%)
      size-with-ext-deps110 kB110 kB+120 B (+0.1%)
    • and

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size42.0 kB42.1 kB+120 B (+0.3%)
      size-with-ext-deps112 kB112 kB+120 B (+0.1%)
    • arrayRemove

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size29.4 kB29.5 kB+120 B (+0.4%)
      size-with-ext-deps99.8 kB100 kB+120 B (+0.1%)
    • arrayUnion

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size29.4 kB29.5 kB+120 B (+0.4%)
      size-with-ext-deps99.8 kB100 kB+120 B (+0.1%)
    • average

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size19.6 kB19.7 kB+120 B (+0.6%)
      size-with-ext-deps89.7 kB89.8 kB+120 B (+0.1%)
    • clearIndexedDbPersistence

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size24.1 kB24.2 kB+120 B (+0.5%)
      size-with-ext-deps94.3 kB94.4 kB+120 B (+0.1%)
    • collection

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size20.3 kB20.4 kB+120 B (+0.6%)
      size-with-ext-deps90.4 kB90.5 kB+120 B (+0.1%)
    • collectionGroup

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size19.3 kB19.4 kB+120 B (+0.6%)
      size-with-ext-deps89.4 kB89.5 kB+120 B (+0.1%)
    • connectFirestoreEmulator

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size17.1 kB17.4 kB+255 B (+1.5%)
      size-with-ext-deps87.8 kB88.4 kB+586 B (+0.7%)

      External Dependency

      ModuleBase (4e6a5c6)Merge (243afc0)Diff
      @firebase/util

      FirebaseError
      createMockUserToken

      FirebaseError
      createMockUserToken
      deepEqual

      + deepEqual

    • count

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.5 kB15.6 kB+120 B (+0.8%)
      size-with-ext-deps85.5 kB85.7 kB+120 B (+0.1%)
    • deleteAllPersistentCacheIndexes

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size95.9 kB96.0 kB+120 B (+0.1%)
      size-with-ext-deps168 kB168 kB+120 B (+0.1%)
    • deleteDoc

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size123 kB123 kB+120 B (+0.1%)
      size-with-ext-deps195 kB195 kB+120 B (+0.1%)
    • deleteField

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.7 kB15.8 kB+120 B (+0.8%)
      size-with-ext-deps85.8 kB85.9 kB+120 B (+0.1%)
    • disableNetwork

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size112 kB112 kB+120 B (+0.1%)
      size-with-ext-deps183 kB184 kB+120 B (+0.1%)
    • disablePersistentCacheIndexAutoCreation

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size95.9 kB96.0 kB+120 B (+0.1%)
      size-with-ext-deps167 kB168 kB+120 B (+0.1%)
    • doc

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size20.8 kB20.9 kB+120 B (+0.6%)
      size-with-ext-deps91.0 kB91.1 kB+120 B (+0.1%)
    • documentId

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size18.6 kB18.7 kB+120 B (+0.6%)
      size-with-ext-deps88.7 kB88.8 kB+120 B (+0.1%)
    • enableIndexedDbPersistence

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size186 kB186 kB+120 B (+0.1%)
      size-with-ext-deps258 kB258 kB+120 B (+0.0%)
    • enableMultiTabIndexedDbPersistence

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size222 kB222 kB+120 B (+0.1%)
      size-with-ext-deps294 kB294 kB+120 B (+0.0%)
    • enableNetwork

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size112 kB112 kB+120 B (+0.1%)
      size-with-ext-deps183 kB184 kB+120 B (+0.1%)
    • enablePersistentCacheIndexAutoCreation

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size95.9 kB96.0 kB+120 B (+0.1%)
      size-with-ext-deps167 kB168 kB+120 B (+0.1%)
    • endAt

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size42.2 kB42.4 kB+120 B (+0.3%)
      size-with-ext-deps112 kB113 kB+120 B (+0.1%)
    • endBefore

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size42.2 kB42.4 kB+120 B (+0.3%)
      size-with-ext-deps112 kB113 kB+120 B (+0.1%)
    • ensureFirestoreConfigured

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size18.5 kB18.7 kB+120 B (+0.6%)
      size-with-ext-deps88.6 kB88.8 kB+120 B (+0.1%)
    • executeWrite

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size122 kB122 kB+120 B (+0.1%)
      size-with-ext-deps194 kB194 kB+120 B (+0.1%)
    • getAggregateFromServer

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size119 kB119 kB+120 B (+0.1%)
      size-with-ext-deps191 kB191 kB+120 B (+0.1%)
    • getCountFromServer

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size119 kB120 kB+120 B (+0.1%)
      size-with-ext-deps191 kB191 kB+120 B (+0.1%)
    • getDoc

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size154 kB154 kB+120 B (+0.1%)
      size-with-ext-deps226 kB226 kB+120 B (+0.1%)
    • getDocFromCache

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size104 kB104 kB+120 B (+0.1%)
      size-with-ext-deps175 kB176 kB+120 B (+0.1%)
    • getDocFromServer

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size154 kB154 kB+120 B (+0.1%)
      size-with-ext-deps226 kB226 kB+120 B (+0.1%)
    • getDocs

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size155 kB155 kB+120 B (+0.1%)
      size-with-ext-deps227 kB227 kB+120 B (+0.1%)
    • getDocsFromCache

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size111 kB112 kB+120 B (+0.1%)
      size-with-ext-deps183 kB183 kB+120 B (+0.1%)
    • getDocsFromServer

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size155 kB155 kB+120 B (+0.1%)
      size-with-ext-deps227 kB227 kB+120 B (+0.1%)
    • getFirestore

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size17.4 kB17.6 kB+256 B (+1.5%)
      size-with-ext-deps95.7 kB95.9 kB+238 B (+0.2%)

      External Dependency

      ModuleBase (4e6a5c6)Merge (243afc0)Diff
      @firebase/util

      FirebaseError
      createMockUserToken
      getDefaultEmulatorHostnameAndPort

      FirebaseError
      createMockUserToken
      deepEqual
      getDefaultEmulatorHostnameAndPort

      + deepEqual

    • getPersistentCacheIndexManager

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size19.7 kB19.8 kB+120 B (+0.6%)
      size-with-ext-deps89.8 kB89.9 kB+120 B (+0.1%)
    • increment

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size16.2 kB16.3 kB+120 B (+0.7%)
      size-with-ext-deps86.3 kB86.4 kB+120 B (+0.1%)
    • initializeFirestore

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size16.2 kB16.3 kB+120 B (+0.7%)
      size-with-ext-deps86.8 kB86.9 kB+120 B (+0.1%)
    • limit

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size16.3 kB16.4 kB+120 B (+0.7%)
      size-with-ext-deps86.4 kB86.5 kB+120 B (+0.1%)
    • limitToLast

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size16.3 kB16.4 kB+120 B (+0.7%)
      size-with-ext-deps86.4 kB86.5 kB+120 B (+0.1%)
    • loadBundle

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size121 kB121 kB+120 B (+0.1%)
      size-with-ext-deps193 kB193 kB+120 B (+0.1%)
    • memoryEagerGarbageCollector

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size84.3 kB84.4 kB+120 B (+0.1%)
      size-with-ext-deps156 kB156 kB+120 B (+0.1%)
    • memoryLocalCache

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size106 kB106 kB+120 B (+0.1%)
      size-with-ext-deps178 kB178 kB+120 B (+0.1%)
    • memoryLruGarbageCollector

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size90.8 kB90.9 kB+120 B (+0.1%)
      size-with-ext-deps162 kB163 kB+120 B (+0.1%)
    • namedQuery

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size96.7 kB96.9 kB+120 B (+0.1%)
      size-with-ext-deps168 kB168 kB+120 B (+0.1%)
    • onSnapshot

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size156 kB156 kB+120 B (+0.1%)
      size-with-ext-deps228 kB228 kB+120 B (+0.1%)
    • onSnapshotsInSync

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size145 kB145 kB+120 B (+0.1%)
      size-with-ext-deps217 kB217 kB+120 B (+0.1%)
    • or

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size42.0 kB42.1 kB+120 B (+0.3%)
      size-with-ext-deps112 kB112 kB+120 B (+0.1%)
    • orderBy

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size20.6 kB20.7 kB+120 B (+0.6%)
      size-with-ext-deps90.7 kB90.8 kB+120 B (+0.1%)
    • persistentLocalCache

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size182 kB182 kB+120 B (+0.1%)
      size-with-ext-deps254 kB254 kB+120 B (+0.0%)
    • persistentMultipleTabManager

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size218 kB218 kB+120 B (+0.1%)
      size-with-ext-deps290 kB290 kB+120 B (+0.0%)
    • persistentSingleTabManager

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size182 kB182 kB+120 B (+0.1%)
      size-with-ext-deps254 kB254 kB+120 B (+0.0%)
    • query

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size42.3 kB42.4 kB+120 B (+0.3%)
      size-with-ext-deps113 kB113 kB+120 B (+0.1%)
    • queryEqual

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size39.3 kB39.5 kB+120 B (+0.3%)
      size-with-ext-deps110 kB110 kB+120 B (+0.1%)
    • refEqual

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size19.7 kB19.9 kB+120 B (+0.6%)
      size-with-ext-deps89.9 kB90.0 kB+120 B (+0.1%)
    • runTransaction

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size133 kB133 kB+120 B (+0.1%)
      size-with-ext-deps205 kB205 kB+120 B (+0.1%)
    • serverTimestamp

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.6 kB15.7 kB+120 B (+0.8%)
      size-with-ext-deps85.7 kB85.8 kB+120 B (+0.1%)
    • setDoc

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size132 kB132 kB+120 B (+0.1%)
      size-with-ext-deps204 kB204 kB+120 B (+0.1%)
    • setIndexConfiguration

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size99.3 kB99.4 kB+120 B (+0.1%)
      size-with-ext-deps171 kB171 kB+120 B (+0.1%)
    • setLogLevel

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.3 kB15.5 kB+120 B (+0.8%)
      size-with-ext-deps85.4 kB85.5 kB+120 B (+0.1%)
    • snapshotEqual

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size45.0 kB45.2 kB+120 B (+0.3%)
      size-with-ext-deps115 kB115 kB+120 B (+0.1%)
    • startAfter

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size42.2 kB42.4 kB+120 B (+0.3%)
      size-with-ext-deps112 kB113 kB+120 B (+0.1%)
    • startAt

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size42.2 kB42.4 kB+120 B (+0.3%)
      size-with-ext-deps112 kB113 kB+120 B (+0.1%)
    • sum

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size19.5 kB19.7 kB+120 B (+0.6%)
      size-with-ext-deps89.7 kB89.8 kB+120 B (+0.1%)
    • terminate

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.4 kB15.5 kB+120 B (+0.8%)
      size-with-ext-deps85.7 kB85.8 kB+120 B (+0.1%)
    • updateDoc

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size132 kB132 kB+120 B (+0.1%)
      size-with-ext-deps204 kB204 kB+120 B (+0.1%)
    • vector

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size15.6 kB15.7 kB+120 B (+0.8%)
      size-with-ext-deps85.7 kB85.8 kB+120 B (+0.1%)
    • waitForPendingWrites

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size112 kB112 kB+120 B (+0.1%)
      size-with-ext-deps184 kB184 kB+120 B (+0.1%)
    • where

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size41.5 kB41.6 kB+120 B (+0.3%)
      size-with-ext-deps112 kB112 kB+120 B (+0.1%)
    • writeBatch

      Size

      TypeBase (4e6a5c6)Merge (243afc0)Diff
      size134 kB134 kB+120 B (+0.1%)
      size-with-ext-deps206 kB206 kB+120 B (+0.1%)

Test Logs

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

@DellaBitta DellaBitta marked this pull request as ready for review February 10, 2025 19:48
@DellaBitta DellaBitta requested review from a team as code owners February 10, 2025 19:48
@@ -494,4 +494,5 @@ export class WriteBatch {
// @public
export function writeBatch(firestore: Firestore): WriteBatch;


Copy link
Contributor

Choose a reason for hiding this comment

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

i did not see this API proposal 😮

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It was a blank document. :)

Copy link
Contributor

@MarkDuckworth MarkDuckworth left a comment

Choose a reason for hiding this comment

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

LGTM. However, the description says this fixes #6824, but that is related to Auth. Not a big deal because you're apply this to auth at the same time, but in a different PR.

@DellaBitta
Copy link
Contributor Author

LGTM. However, the description says this fixes #6824, but that is related to Auth. Not a big deal because you're apply this to auth at the same time, but in a different PR.

Righto, removed that Fixes comment in the PR. Thanks for the review!

@DellaBitta DellaBitta merged commit 69c3326 into main Feb 11, 2025
49 checks passed
@DellaBitta DellaBitta deleted the ddb-firestore-emulator-reconnect branch February 11, 2025 21:47
@firebase firebase locked and limited conversation to collaborators Mar 14, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants