Descriptionchromeos: Destruct DriveResourceMetadata on the blocking pool
Make DriveResourceMetadata's dtor private, add Destroy().
Add DestroyHelper to drive_file_system_util.h
Add DestroyHelperForTests to drive_test_util.h and replace DeleteDriveCache with it.
After switching to DB storage, DriveResourceMetadata will post tasks to the blocking pool.
Since we'd like to avoid locking the UI thread, we don't want to wait for the completion of tasks on the blocking pool.
It means that DriveResourceMetadata must live longer than any tasks posted on the blocking pool.
To achieve this, we post a task to delete DriveResourceMetadata on the blocking pool like DriveCache.
BUG=147299
TEST=unit_tests
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=188818
Patch Set 1 : _ #
Total comments: 8
Patch Set 2 : Review fix #Patch Set 3 : rebase #Patch Set 4 : Add note #Messages
Total messages: 7 (0 generated)
|