Closed Bug 1913561 Opened 3 months ago Closed 1 month ago

Cover temporary storage initialization in OpenStorageDirectory and OpenClientDirectory

Categories

(Core :: Storage: Quota Manager, task, P1)

task

Tracking

()

RESOLVED FIXED
133 Branch
Tracking Status
firefox133 --- fixed

People

(Reporter: janv, Assigned: janv)

References

(Blocks 1 open bug)

Details

Attachments

(7 files)

48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review
48 bytes, text/x-phabricator-request
Details | Review

Quota clients and origin operations currently still have to call EnsureTemporaryStorageIsInitializedInternal method
on the QM IO thread. This should be covered by OpenStorageDirectory and OpenClientDirectory instead.

QuotaManager::OpenClientDirectory can now detect the requested persistence type
and initialize temporary storage if it's needed.

QuotaManager::OpenClientDirectory already makes sure that temporary storage
is initialized so all these calls are now redundant.

QuotaManager::OpenStorageDirectory can now detect the requested persistence
scope and initialize temporary storage if it's needed.

QuotaManager::OpenStorageDirectory already makes sure that temporary storage
is initialized so all these calls are now redundant.

The goal to call QuotaManager::EnsureTemporaryStorageIsInitializedInternal only
from InitTemporaryStorageOp has been achieved. It's now easy to change the
method to be a private method.

TestQuotaManager.cpp is getting big and the use of the Await helper reduces the
size of the file significantly and also make the tests more readable.

These additional tests are mainly to improve code coverage of
QuotaManager::InitializeTemporaryStorage method.

Depends on: 1913679
No longer depends on: 1866217
Depends on: 1914609
No longer depends on: 1913679
Depends on: 1919788
No longer depends on: 1914609
Depends on: 1920456
No longer depends on: 1919788
Depends on: 1920487
No longer depends on: 1920456
Pushed by jvarga@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/e71e9e1b3c05 Add support for initializing temporary storage to QuotaManager::OpenClientDirectory; r=dom-storage-reviewers,jari
Pushed by jvarga@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/fd9998d8fc7c Remove QuotaManager::EnsureTemporaryStorageIsInitializedInternal calls from places where a directory lock is obtained via QuotaManager::OpenClientDirectory; r=dom-storage-reviewers,jari
Pushed by jvarga@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/5e75c0736a58 Add support for initializing temporary storage to QuotaManager::OpenStorageDirectory; r=dom-storage-reviewers,jari
Pushed by jvarga@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/0de4d89cea21 Remove QuotaManager::EnsureTemporaryStorageIsInitializedInternal calls from places where a directory lock is obtained via QuotaManager::OpenStorageDirectory; r=dom-storage-reviewers,jari
Keywords: leave-open
Pushed by jvarga@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/895ce008cc48 Change QuotaManager::EnsureTemporaryStorageIsInitializedInternal to be a private method; r=dom-storage-reviewers,jari https://hg.mozilla.org/integration/autoland/rev/7159f6e61248 Update QuotaManager gtests to use Await instead of manual spinning of the event loop; r=dom-storage-reviewers,jari https://hg.mozilla.org/integration/autoland/rev/a71f2a1191d8 Add more tests for QuotaManager::InitializeTemporaryStorage method; r=dom-storage-reviewers,jari
Blocks: 1923056
No longer blocks: 1866402
Status: ASSIGNED → RESOLVED
Closed: 1 month ago
Resolution: --- → FIXED
Target Milestone: --- → 133 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: