Changes between Version 34 and Version 35 of Ticket #394

02/18/2015 04:09:04 PM (6 years ago)

I've updated the description with the latest version of the data format including subscription source, FirstParty and ThirdParty filters. As I've mentioned in current comment. This was initially requested so far as I can see from the @Sebastian handover email.

Also Added Addition Notes which was discussed during implementation with @palant, but missing in description Like what database we can use to store the data on client side.


  • Ticket #394 – Description

    v34 v35  
    44=== What to change === 
    55Add a setting to Adblock Plus for Firefox, in order to collect filter hit statistics and pushing them to our server. The setting must be disabled by default. 
     6Setting label: "Help us improve ABP by sending anonymous statistics". 
    78Regardless of that setting, no data must be collected while in private browsing mode. And collected data must be discarded when the history is cleared. 
    1516  "version": 1,               // For the server to recognize outdated clients 
    16   "timeSincePush": 12345,     // Time interval (milliseconds) since previous push 
     17  "timeSincePush": 12345,     // UTC Time interval (milliseconds) since previous push 
    1718  "addonName": "adblockplus", // see require("info") 
    1819  "addonVersion": "2.3.4",    // see require("info") 
    2324  "filters": { 
    2425    "||^": { 
    25       "": {"hits": 12, "latest": 123456789}, 
    26       "": {"hits": 4, "latest": 987654321} 
     26      firstParty: { 
     27        "": { 
     28          "hits": 12,         // Number of hits 
     29          "latest": 123456789 // UTC Time interval (milliseconds) of last hit 
     30        }, 
     31        "": {"hits": 4, "latest": 987654321} 
     32      }, 
     33      thirdParty: { 
     34        "": {"hits": 5, "latest": 123455489} 
     35      }, 
     36      subscriptions: ["EasyList", "EasyList Germany+EasyList"] 
    2737    }, 
    2838    " > bar": { 
    3444Important: the data should include only filters from filter subscriptions, not the user's own filters. After successfully sending that data to the server the client should clear all the data it saved and start collecting statistics from scratch. 
    36 Note: The `latest` timestamp field must account for the user's local timezone. The server server expects the timestamp to be in UTC. 
     46=== Additional notes === 
     47The data first should be collected into the memory and being saved on client side using [ Storage API] when solid amount of filters is being hit (Ex.: using filterListener's setDirty method). 
     49Each time the data is being successfully sent to our server the data should be deleted from client.