Open
Bug 1512750
Opened 4 years ago
Updated 5 months ago
Having a marker file before removing files in QuotaManager
Categories
(Core :: Storage: Quota Manager, enhancement, P2)
Core
Storage: Quota Manager
Tracking
()
NEW
People
(Reporter: tt, Unassigned)
References
(Depends on 1 open bug, Blocks 1 open bug)
Details
Attachments
(1 file)
Given there is still a sightly chance to fail during removing an origin directory (unexpected thing like OS holds a file in that directory). We should have a token/marker file to indicate whether QuotaManager has removed all the files in the giving directory or not. On the other hands, if the QuotaManager finds out the marker file in the next operation/initialization, it should complete the rest of removing.
Updated•4 years ago
|
Priority: -- → P2
Reporter | ||
Comment 1•4 years ago
|
||
In this bug, we should do:
- Create a marker file before the deletion and remove it after the deletion if the deletion succeeded.
- Have a hashtable as an inaccessible list so that we don't need to always check the marker files while accessing an origin.
- Note: Should have a check in EnsureOriginIsInitialized(). If the storage has initialized, we should check the hashtable. Otherwise, check the file.
Concerns:
- If the marker file lives in the persistence-type folder (default/permanent/temporary), it means the initialization time might increase, since we need to scan whole the files first and then check if there is an origin directory marked by a marker file.
Assignee: nobody → shes050117
Status: NEW → ASSIGNED
Reporter | ||
Comment 2•4 years ago
|
||
(In reply to Tom Tung [:tt, :ttung] from comment #1)
- Create a marker file before the deletion and remove it after the deletion if the deletion succeeded.
This would be renaming the .metadata-v2 file before the deletion.
Then, deletion other files.
Finally, remove the renamed metadata file and the origin directory.
Reporter | ||
Comment 3•4 years ago
|
||
Comment 5•3 years ago
|
||
We currently support clearing of files for specific origin and quota client only, so multiple markers would be needed to do it correctly. Again, I think this will be easier after bug 1593365.
Reporter | ||
Updated•3 years ago
|
Assignee: ttung → nobody
Status: ASSIGNED → NEW
Updated•2 years ago
|
Assignee: nobody → shes050117
Status: NEW → ASSIGNED
Updated•2 years ago
|
Assignee: shes050117 → nobody
Status: ASSIGNED → NEW
Updated•5 months ago
|
Severity: normal → S3
You need to log in
before you can comment on or make changes to this bug.
Description
•