Closed
Bug 406865
Opened 17 years ago
Closed 17 years ago
need to clobber broken urlclassifier3.sqlite files
Categories
(Toolkit :: Safe Browsing, defect)
Toolkit
Safe Browsing
Tracking
()
RESOLVED
FIXED
People
(Reporter: dcamp, Assigned: dcamp)
References
Details
Attachments
(1 file, 1 obsolete file)
(deleted),
patch
|
tony
:
review+
damons
:
approval1.9+
|
Details | Diff | Splinter Review |
Bugs 406621 and 406856 will have left some expired blacklist entries in the database.
Additionally, apparently sometime in early November google reset their database, which will have left a lot of databases in an inconsistent state.
The attached patch will clobber any database created by the old builds, and start updating fresh. We should land this once 406856 lands.
Attachment #291524 -
Flags: review?(tony)
Assignee | ||
Comment 1•17 years ago
|
||
The google people Might be doing one more database rebuild sometime this week. If they decide to do that, we should wait to land this patch until they've done that.
After that, we need google to rarely-if-ever reset the database again, and build a good way to recover from resets into the protocol (rather than just leaving databases in an inconsistent state).
Updated•17 years ago
|
Flags: blocking-firefox3?
Comment 2•17 years ago
|
||
Comment on attachment 291524 [details] [diff] [review]
clobber out-of-date databases
>+ if (databaseVersion != IMPLEMENTATION_VERSION) {
>+ LOG(("Incompatible database, removing."));
>+
>+ rv = connection->Close();
>+ NS_ENSURE_SUCCESS(rv, rv);
>+
>+ rv = mDBFile->Remove(PR_FALSE);
>+ NS_ENSURE_SUCCESS(rv, rv);
>+
>+ rv = storageService->OpenDatabase(mDBFile, getter_AddRefs(connection));
>+ NS_ENSURE_SUCCESS(rv, rv);
>+ }
>+
>+ rv = connection->SetSchemaVersion(IMPLEMENTATION_VERSION);
>+ NS_ENSURE_SUCCESS(rv, rv);
Can we put the SetSchemaVersion in the if block?
The rest looks good.
Attachment #291524 -
Flags: review?(tony) → review+
Assignee | ||
Comment 3•17 years ago
|
||
new version doesn't check the schema on a newly-created database.
Attachment #291524 -
Attachment is obsolete: true
Attachment #291548 -
Flags: review?(tony)
Comment 4•17 years ago
|
||
Comment on attachment 291548 [details] [diff] [review]
v2
Yeah, I like this better.
Attachment #291548 -
Flags: review?(tony) → review+
Assignee | ||
Comment 5•17 years ago
|
||
Comment on attachment 291548 [details] [diff] [review]
v2
Google isn't going to be rebuilding their database, so this should be ready to land.
Attachment #291548 -
Flags: approval1.9?
Updated•17 years ago
|
Attachment #291548 -
Flags: approval1.9? → approval1.9+
Assignee | ||
Comment 6•17 years ago
|
||
Checking in src/nsUrlClassifierDBService.cpp;
/cvsroot/mozilla/toolkit/components/url-classifier/src/nsUrlClassifierDBService.cpp,v <-- nsUrlClassifierDBService.cpp
new revision: 1.44; previous revision: 1.43
done
Status: NEW → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
Comment 7•17 years ago
|
||
dave, this should indirectly fix that bug polvi was seeing, right? (bug #406505)
Updated•17 years ago
|
Flags: blocking-firefox3? → blocking-firefox3+
Updated•10 years ago
|
Product: Firefox → Toolkit
You need to log in
before you can comment on or make changes to this bug.
Description
•