Bug 31440 - Add Chromium's DatabaseTracker implementation to WebKit
Summary: Add Chromium's DatabaseTracker implementation to WebKit
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Dumitru Daniliuc
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-11-12 14:44 PST by Dumitru Daniliuc
Modified: 2009-11-13 13:12 PST (History)
4 users (show)

See Also:


Attachments
patch (15.85 KB, patch)
2009-11-12 14:57 PST, Dumitru Daniliuc
dumi: commit-queue-
Details | Formatted Diff | Diff
patch (15.22 KB, patch)
2009-11-12 22:13 PST, Dumitru Daniliuc
dglazkov: review+
dumi: commit-queue-
Details | Formatted Diff | Diff
patch (15.54 KB, patch)
2009-11-13 11:43 PST, Dumitru Daniliuc
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dumitru Daniliuc 2009-11-12 14:44:22 PST
Add Chromium's DatabaseTracker implementation.
Comment 1 Dumitru Daniliuc 2009-11-12 14:57:38 PST
Created attachment 43103 [details]
patch

Somebody from Apple (Brady, Anders?) should REALLY take a look at the changes to DatabaseTracker.h. Chromium doesn't need a lot of things declared in DatabaseTracker.h, so I #ifdef'd them out.
Comment 2 Michael Nordman 2009-11-12 17:39:26 PST
I would prefer to maintain the symmetry between these two method names...


class QuotaTracker
    void getDatabaseSizeAndSpaceAvailableToOrigin(
        const String& originIdentifier, const String& databaseName,
        unsigned long long* databaseSize, unsigned long long* spaceAvailable);
    void updateDatabaseSizeAndSpaceAvailableToOrigin(
        const String& originIdentifier, const String& databaseName,
        unsigned long long databaseSize, unsigned long long spaceAvailable);


... otherwise lgtm
Comment 3 Dumitru Daniliuc 2009-11-12 22:13:14 PST
Created attachment 43133 [details]
patch

Addressed Michael's comment regarding naming inconsistency in QuotaTracker.{h|cpp}.
Comment 4 Dimitri Glazkov (Google) 2009-11-13 09:46:54 PST
Comment on attachment 43133 [details]
patch

I don't like how DatabaseTracker is so fragmented by the ifdefs. It's fine for now, but ideally this really needs to be abstracted by purpose and the lines of implementation drawn along that. Can you file a bug on this?
Comment 5 Dumitru Daniliuc 2009-11-13 11:43:22 PST
Created attachment 43175 [details]
patch

Commented out DatabaseTrackerChromium::removeOpenDatabase(). Its current implementation is causing some subtle problems when running layout tests in test_shell, and we don't even use this information yet anyway.
Comment 6 Dumitru Daniliuc 2009-11-13 11:47:21 PST
(In reply to comment #4)
> (From update of attachment 43133 [details])
> I don't like how DatabaseTracker is so fragmented by the ifdefs. It's fine for
> now, but ideally this really needs to be abstracted by purpose and the lines of
> implementation drawn along that. Can you file a bug on this?

Done. Filed bug 31482.
Comment 7 Dumitru Daniliuc 2009-11-13 12:25:42 PST
Landed as r50961.
Comment 8 Eric Seidel (no email) 2009-11-13 13:12:19 PST
Comment on attachment 43175 [details]
patch

clearing r=? since it looks like this was landed.