Closed Bug 997786 Opened 11 years ago Closed 8 years ago

Lack of quota API - implement prefixed functionality

Categories

(Core :: Storage: IndexedDB, defect)

28 Branch
x86
macOS
defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: guypaskar, Unassigned)

References

Details

User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:28.0) Gecko/20100101 Firefox/28.0 (Beta/Release) Build ID: 20140314220517 Steps to reproduce: When using indexedDB - a website must know how much storage he can use without taking all of user's disk space. Quota API takes care of that. However - it is not implemented yet and the API is still in discussions therefore - it might take time until it could be implemented. This is preventing developers that want to use indexedDB without harming the end user from implementing their web applications. Actual results: There are two main issues: 1) There is no way to know how much free disk space the user has. 2) there is no way to know if I got a write error that is related to disk space. Expected results: 1) I suggest to implement a really simple prefixed API to know how much free space there is - so that a website can decide if he can or cannot write data. this is the least functionality that is needed (and is not supposed to be difficult to implement) 2) When getting an error while writing to indexedDB, if the error happened due to lack of space the developer should be aware of that so he/she can delete data that she already wrote and act accordingly.
Component: Untriaged → File Handling
I would find it very useful to just know how much free space is left for the application, even if it's a query that is correct only for the time the query is taken.
Component: File Handling → DOM: IndexedDB
Product: Firefox → Core
(In reply to guy paskar from comment #0) > 1) There is no way to know how much free disk space the user has. This should be fixed soon by bug 1267941
Status: UNCONFIRMED → NEW
Depends on: 1267941
Ever confirmed: true
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.