[webkit-reviews] review denied: [Bug 27967] Decouple the code that deals with the main DB and quota management from the rest of the DB code : [Attachment 34104] SQLTransactionClient

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Aug 5 14:13:28 PDT 2009


Dimitri Glazkov (Google) <dglazkov at chromium.org> has denied Dumitru Daniliuc
<dumi at chromium.org>'s request for review:
Bug 27967: Decouple the code that deals with the main DB and quota management
from the rest of the DB code
https://bugs.webkit.org/show_bug.cgi?id=27967

Attachment 34104: SQLTransactionClient
https://bugs.webkit.org/attachment.cgi?id=34104&action=review

------- Additional Comments from Dimitri Glazkov (Google)
<dglazkov at chromium.org>
I think you should just name SQLTransactionClient implementation
SQLTransactionClient.cpp. There's no need to do an extra suffix. If you intend
to provide a separate implementation in Chromium,
you can provide it in platform/chromium and name it
SQLTransactionClientChromium.cpp.

Overall, the idea sounds great!

> Index: WebCore/ChangeLog
> ===================================================================
> --- WebCore/ChangeLog (revision 46789)
> +++ WebCore/ChangeLog (working copy)
> @@ -1,3 +1,47 @@
> +2009-08-04  Dumitru Daniliuc  <dumi at chromium.org>
> +
> +	   Reviewed by NOBODY (OOPS!).
> +
> +	   Added a "listener" interface to SQLTransaction that allows us to

You can just say a client to SQLTransaction. It's a common term here.

>				>
>			</File>
>			<File
> +			       
RelativePath="..\storage\SQLTransactionClient.h"
> +				>
> +			</File>
> +			<File
> +			       
RelativePath="..\storage\SQLTransactionClientImpl.cpp"
> +				>
> +			</File>
> +			<File
>			       
RelativePath="..\storage\SQLTransactionErrorCallback.h"
>				>
>			</File>


You will need to make changes to all build systems that currently use
SQLTransaction.

> Index: WebCore/storage/Database.cpp
> ===================================================================
> --- WebCore/storage/Database.cpp	(revision 46789)
> +++ WebCore/storage/Database.cpp	(working copy)
> @@ -50,6 +50,7 @@
>  #include "SQLiteFileSystem.h"
>  #include "SQLiteStatement.h"
>  #include "SQLResultSet.h"
> +#include "SQLTransactionClient.h"
>  #include <wtf/MainThread.h>
>  #endif
>  
> @@ -136,6 +137,7 @@ Database::Database(Document* document, c
>      , m_deleted(false)
>      , m_stopped(false)
>      , m_opened(false)
> +    , m_transactionClient(new SQLTransactionClient())

What's the point of a client if you don't pass it in as an argument?

> Index: WebCore/storage/SQLTransactionClientImpl.cpp
> ===================================================================
> +namespace WebCore {
> +
> +void SQLTransactionClient::databaseChanged(Database* database) {
> + 
DatabaseTracker::tracker().scheduleNotifyDatabaseChanged(database->securityOrig
inCopy().get(), database->stringIdentifier());

4 spaces, brace on new line.

> +void SQLTransactionClient::databaseSizeChanged(Database* database) {

brace on new line.

> +bool SQLTransactionClient::databaseExceedsQuota(Database* database) {

brace on new line.


More information about the webkit-reviews mailing list