Re: [IndexedDB] Granting storage quotas

2010-05-06 Thread Dumitru Daniliuc
nikunj, i agree with what jeremy said. i think we need each storage API to be able to specify what kind of storage it needs (and i'm trying to add an optional flag for that to WebSQLDatabases, which is your option #1). in addition to that, i think we need an API that would allow an app to request p

Re: [IndexedDB] Granting storage quotas

2010-05-04 Thread Dumitru Daniliuc
ian, it seems to me that nobody objects to adding a isPersistent optional parameter to openDatabase{Sync}() in the WebSQLDatabases spec (default = false). can you please add it to the spec? if isPersistent = true and the UA doesn't support persistent storage, then i believe openDatabase{Sync}() sho

Re: [IndexedDB] Granting storage quotas

2010-04-28 Thread Dumitru Daniliuc
shawn, did you have a chance to give this some thought? how would mozilla like to handle cases like the ones jeremy and robin mentioned? how would you like to manage quotas? thanks, dumi On Fri, Apr 23, 2010 at 11:08 AM, Shawn Wilsher wrote: > On 4/23/2010 7:39 AM, Nikunj Mehta wrote: > >> Co

Re: [IndexedDB] Granting storage quotas

2010-04-22 Thread Dumitru Daniliuc
fwiw, i agree with michael and tab that we should split all storage into "permanent/persistent" and "temporary/evictable/purgeable". however, i don't think we need separate calls such as openDatabase() and openPermanentDatabase(). i think we should just add an optional isPersistent parameter to ope

Re: [WebSQLDatabase] Adding a vacuum() call

2010-03-17 Thread Dumitru Daniliuc
, Mar 16, 2010 at 5:03 PM, João Eiras wrote: > On Wed, 17 Mar 2010 01:50:00 +0100, Dumitru Daniliuc > wrote: > > shane, i was hoping you could clarify a few things about AUTO_VACUUM: >> >> > Perhaps this is a bit out of scope of this mailing list ? > > >

Re: [WebSQLDatabase] Adding a vacuum() call

2010-03-16 Thread Dumitru Daniliuc
shane, i was hoping you could clarify a few things about AUTO_VACUUM: > However, the B-Tree balancing algorithm used by SQLite will attempt to > merge pages with neighbors when there space utilization drops below certain > thresholds. Minimum average fill for intkey leaves is 50%. For other pages

Re: [WebSQLDatabase] Adding a vacuum() call

2010-03-12 Thread Dumitru Daniliuc
>> wrote: >> > Instead of calling back on success only, maybe call back on completion >> > regardless of success or failure. This way the caller would know when >> the >> > potentially lengthy operation was done, regardless of the outcome. >> > >> >

Re: [WebSQLDatabase] Adding a vacuum() call

2010-03-11 Thread Dumitru Daniliuc
On Thu, Mar 11, 2010 at 7:17 PM, João Eiras wrote: > On Fri, 12 Mar 2010 04:07:21 +0100, Dumitru Daniliuc > wrote: > > joao, >> >> if i understand correctly, you basically want to have an automated system >> implemented in the browser that decides when to vacuum

Re: [WebSQLDatabase] Adding a vacuum() call

2010-03-11 Thread Dumitru Daniliuc
2. the completion callback is called as soon as UA believes the DB is in a good shape. what do you think? thanks, dumi On Thu, Mar 11, 2010 at 4:13 PM, João Eiras wrote: > On Fri, 12 Mar 2010 01:08:41 +0100, Dumitru Daniliuc > wrote: > > joao, >> >> it looks like we

Re: [WebSQLDatabase] Adding a vacuum() call

2010-03-11 Thread Dumitru Daniliuc
at 4:20 PM, Michael Nordman wrote: > Instead of calling back on success only, maybe call back on completion > regardless of success or failure. This way the caller would know when the > potentially lengthy operation was done, regardless of the outcome. > > 2010/3/11 Dumitru Daniliuc >

Re: [WebSQLDatabase] Adding a vacuum() call

2010-03-11 Thread Dumitru Daniliuc
know better than UAs when the best time to vacuum is (it might be nice to give apps more information on how fragmented their databases are, but that's a separate discussion). thanks, dumi 2010/3/9 Jeremy Orlow > On Mon, Mar 8, 2010 at 8:47 PM, Dumitru Daniliuc wrote: > >> >

Re: [WebSQLDatabase] Adding a vacuum() call

2010-03-08 Thread Dumitru Daniliuc
On Mon, Mar 8, 2010 at 3:39 AM, João Eiras wrote: > > I don't see how the callbacks are useful though. Vacuum works >>> transparently, its effects are not visible, and what should the page do >>> in >>> case of error ? >>> >>> >> i was thinking of something like: >> >> db.defragment(errorCallbac

[WebSQLDatabase] Adding a vacuum() call

2010-03-05 Thread Dumitru Daniliuc
(reposting from the right email account) hi joao, thanks for your comments! > I would argue about having something a bit more generic for naming like > "defragment()". > that's totally fine with me. > I don't see how the callbacks are useful though. Vacuum works > transparently, its effects

Re: [WebSQLDatabase] Adding a vacuum() call

2010-03-05 Thread Dumitru Daniliuc
hi joao, thanks for your comments! > I would argue about having something a bit more generic for naming like > "defragment()". > that's totally fine with me. > I don't see how the callbacks are useful though. Vacuum works > transparently, its effects are not visible, and what should the page

[WebSQLDatabase] Adding a vacuum() call

2010-03-04 Thread Dumitru Daniliuc
Hi, We (Chromium) would like to add a vacuum() call on the Database object. The idea is to allow the SQL engine to vacuum/compress/clean-up/do some potentially expensive maintenance work on the respective database. In SQLite's case, in particular, the vacuum() call would issue a VACUUM command (wh

[WebSQLDatabase] openDatabase() creation callback

2010-02-23 Thread Dumitru Daniliuc
Hi, I know that not many people on this list care about the WebSQLDatabase spec anymore (especially when it comes to changing it), but Chromium extension developers do. So I was hoping somebody could explain the idea behind having openDatabase() take a creationCallback. As I understand it, the cal

Re: [WebSQLDatabase] Minor change to spec?

2010-02-01 Thread Dumitru Daniliuc
Thanks for clarifying this, Ian. Dumi On Mon, Feb 1, 2010 at 4:53 PM, Ian Hickson wrote: > On Mon, 1 Feb 2010, Dumitru Daniliuc wrote: > > > > In section 4.3.2, point 6, the "In case of error..." paragraph says: > > > > 2. If the error callback re

[WebSQLDatabase] Minor change to spec?

2010-02-01 Thread Dumitru Daniliuc
In section 4.3.2, point 6, the "In case of error..." paragraph says: 2. If the error callback returns false, then move on to the next statement, if any, or onto the next overall step otherwise. 3. Otherwise, the error callback did not return false, or there was no error callback. Jump to the last

Re: [WebSimpleDatabase] New spec, editor's draft available

2009-09-07 Thread Dumitru Daniliuc
> > http://dev.w3.org/2006/webapi/WebSimpleDatabase/ > FYI: you should probably copy-paste the link that nikunj sent in his email. clicking on it takes you to http://dev.w3.org/2006/webapi/DataCache/. dumi

[web databases] SQLStatementErrorCallback

2009-09-04 Thread Dumitru Daniliuc
Hi, When talking about statement error callbacks (point #6, section 4.3.2), the spec says: 1. If the error callback returns false, then move on to the next statement, if any, or onto the next overall step otherwise. 2. Otherwise, the error callback did not return false, or there was no error callb

Re: [webdatabase] Transaction Locks

2009-09-02 Thread Dumitru Daniliuc
I can't speak for the spec authors, but I can tell you what WebKit does at the moment. We acquire a lock before we run the transaction callback, but just like you, we do not have a timeout that invokes the error callback. So it seems to me like overall our implementations should behave similarly (w