Skip to content

DiskBasedCache breaks if the user clears app cache while the app is still running. #296

@ajnas

Description

@ajnas

When using the default DiskBasedCache, if the app cache gets cleared, the default directory for the volley caches also gets deleted. In this instance, future cache writes happening in the RequestQueue fails as the root directory for saving the cache files does not exist anymore.

Creating the root folder for volley caches (ie, 'volley' folder in cache directory) is done during the start() function of the CacheDispatcher which is triggered during the start of the RequestQueue.

This causes the unexpected cache misses If the app keeps the RequestQueue as a singleton instance in the memory.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions