-
Notifications
You must be signed in to change notification settings - Fork 948
IndexeddbIndexManager.updateEntries() #5999
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
|
4eca730
to
ea903a6
Compare
Size Report 1Affected Products
Test Logs |
Size Analysis Report 1This report is too large (641,979 characters) to be displayed here in a GitHub comment. Please use the below link to see the full report on Google Cloud Storage.Test Logs |
@@ -269,8 +320,176 @@ export class IndexedDbIndexManager implements IndexManager { | |||
transaction: PersistenceTransaction, | |||
documents: DocumentMap | |||
): PersistencePromise<void> { | |||
// TODO(indexing): Implement | |||
return PersistencePromise.resolve(); | |||
const memoizedIndexes = new Map<string, FieldIndex[]>(); |
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.
Looks like Android calls getFieldIndexes
and have the memoization optimization done there? Is there a reason for the deviation?
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.
Added comment:
// Porting Note: `getFieldIndexes()` on Web does not cache index lookups as
// it could be used across different IndexedDB transactions. As any cached
// data might invalidated by other multi-tab clients, we can only trust data
// within a single IndexedDB transaction. We therefore add a cache here.
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.
might -> might be
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!
@@ -269,8 +320,176 @@ export class IndexedDbIndexManager implements IndexManager { | |||
transaction: PersistenceTransaction, | |||
documents: DocumentMap | |||
): PersistencePromise<void> { | |||
// TODO(indexing): Implement | |||
return PersistencePromise.resolve(); | |||
const memoizedIndexes = new Map<string, FieldIndex[]>(); |
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.
might -> might be
This ports the
updateEntries
code from Android.