-
Notifications
You must be signed in to change notification settings - Fork 615
Add FirestoreClientProvider #6050
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
Conversation
…actor' into tomandersen/componentProviderRefactor
Startup Time Report 1Note: Layout is sometimes suboptimal due to limited formatting support on GitHub. Please check this report on GCS. Notes
Startup Times
|
…ClientProvider # Conflicts: # firebase-firestore/src/main/java/com/google/firebase/firestore/core/ComponentProvider.java # firebase-firestore/src/main/java/com/google/firebase/firestore/core/MemoryComponentProvider.java # firebase-firestore/src/main/java/com/google/firebase/firestore/core/SQLiteComponentProvider.java # firebase-firestore/src/test/java/com/google/firebase/firestore/FirebaseFirestoreIntegrationTestFactory.java
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The overall approach looks good, only some minor nits.
firebase-firestore/src/main/java/com/google/firebase/firestore/DocumentReference.java
Outdated
Show resolved
Hide resolved
firebase-firestore/src/main/java/com/google/firebase/firestore/FirebaseFirestore.java
Outdated
Show resolved
Hide resolved
firebase-firestore/src/main/java/com/google/firebase/firestore/FirestoreClientProvider.java
Outdated
Show resolved
Hide resolved
firebase-firestore/src/main/java/com/google/firebase/firestore/core/FirestoreClient.java
Outdated
Show resolved
Hide resolved
firebase-firestore/src/main/java/com/google/firebase/firestore/core/FirestoreClient.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, there are some tests failures though?
Introduce FirestoreClientProvider to manage life cycle and access to FirestoreClient. Calls to FirestoreClient are made through the reference held in FirestoreClientProvider, thereby preparing for swapping FirestoreClient in future PR. This requires rewiring calls, such that code does not hold a direct reference to FirestoreClient.
I am open to a better name than FirestoeClientProvider...