cacheSizeBytes property

int cacheSizeBytes
final

Sets an approximate cache size threshold for the on-disk data. If the cache grows beyond this size, Firestore will start removing data that hasn't been recently used. The size is not a guarantee that the cache will stay below that size, only that if the cache exceeds the given size, cleanup will be attempted.

By default, collection is enabled with a cache size of 100 MB. The minimum value is 1 MB.

When cacheSettings is set this is derived from it: the size of the PersistentCacheSettings, IndexedDbCacheSettings or KeyValueCacheSettings, cacheSizeUnlimited for MemoryCacheSettings.

Implementation

final int cacheSizeBytes;