Closed
Bug 1284178
Opened 9 years ago
Closed 9 years ago
Implement HashStore for v4
Categories
(Toolkit :: Safe Browsing, defect, P2)
Toolkit
Safe Browsing
Tracking
()
RESOLVED
WONTFIX
People
(Reporter: dimi, Assigned: dimi)
References
Details
(Whiteboard: #sbv4-m1)
V4 is not chunk based data anymore, we will need to implement v4 format
Assignee | ||
Comment 1•9 years ago
|
||
Partial update response may contain removal "index" for prefixes. Prefixes should be sorted by their hash values in binary string format in order to find correct index.
So the plan here is to store all the prefixes in database with sorted order.
Assignee | ||
Comment 2•9 years ago
|
||
Another approach is do not store .sbstore for v4 since we will have prefixes in .cache(completions from update), .pset(4-bytes prefix) and .vlpset(variable-length prefix set, bug 1283007).
But in this way we would need to merge all the prefixes from these files and then sort again, also .pset files store prefix and delta. So construct prefixes string from .pset requires extra effort.
Assignee | ||
Updated•9 years ago
|
Whiteboard: #sbv4-v1
Updated•9 years ago
|
Whiteboard: #sbv4-v1 → #sbv4-m1
Assignee | ||
Comment 3•9 years ago
|
||
Hi gcp,
Have one question regarding to v2 implementation. In v2 we will store addPrefixes in both .pset and .sbstore, why do we do that? can we just store them in .pset ?
Since v4 is not chunk based anymore, there is only prefixes and completions, so I am thinking keep 4-bytes prefixes in .pset like what we are doing right now and put others(server state, variable-length prefixes, completions) in .sbstore. how do you think ?
Flags: needinfo?(gpascutto)
Comment 4•9 years ago
|
||
>Have one question regarding to v2 implementation. In v2 we will store addPrefixes in
>both .pset and .sbstore, why do we do that? can we just store them in .pset ?
First of all, the data isn't duplicated: the actual prefixes are (only) in .pset, and the chunk data from those add prefixes is (only) in .sbtore. The chunk data is only needed for updates, not for lookups. So we don't have to open and read HashStore unless we update. That said, the real reason is that PrefixSet existed and was used before HashStore was written, so HashStore just carries the missing information that PrefixSet didn't carry yet (chunks). That avoided an incompatible change in the .pset format.
For v4 this all no longer applies and you can put all prefix data in .pset.
Flags: needinfo?(gpascutto)
Assignee | ||
Comment 5•9 years ago
|
||
(In reply to Gian-Carlo Pascutto [:gcp] from comment #4)
> so HashStore
> just carries the missing information that PrefixSet didn't carry yet
> (chunks). That avoided an incompatible change in the .pset format.
>
> For v4 this all no longer applies and you can put all prefix data in .pset.
Thank you for the clarification!
Updated•9 years ago
|
Updated•9 years ago
|
Priority: -- → P2
Assignee | ||
Comment 6•9 years ago
|
||
According to Comment 4, we will store all prefix data in .pset(Implement in Bug 1283007)
So we won't need HashStore for v4.
Set this bug as won't fix.
Status: ASSIGNED → RESOLVED
Closed: 9 years ago
Resolution: --- → WONTFIX
You need to log in
before you can comment on or make changes to this bug.
Description
•