AdSweep Online

2nd January, 2010

Last time, when I first took over AdSweep’s maintenance, I tried an experiment to have the database of rules on my server and to have the extension simply insert the stylesheet generated by my server into the page. This worked fine in my testing, but apparently it didn’t work too well for most people. So I scrapped it and began thinking about a new way of doing it.

Chrome’s extension system provides a few advantages. First of all, I have a background page, which is simply a web-page that runs in the background, once per extension. This means that instead of loading all the rules for all the sites included into memory, I can store them once per session. This reduces memory usage by a factor of the amount of tabs open. It also means that retrieving the rules is done in the background and no longer slows down loading the site itself. Another advantage is local storage. What this means is that when rules are downloaded, they can be stored in a cache in the browser, so I can retrieve the rules, store them in a cache and then serve them from the cache the next time they’re needed.

So the way it’s set up now is this. Whenever a page is loaded, a request is made to the background page. This page will serve the page the rules it has in cache, if available. Whenever a page receives rules, it applies them. However, also in the background, the rules are downloaded again, from my site, the cache is updated and the rules the site receive are too. But, in order not to have to visit all those sites, you can also decide to click a button on the options page to download all the rules into the cache, greatly speeding up ad retrieval.

As I’m not going to throw it out immediately without thorough testing, please leave a comment below if you’re interested in testing this idea.

Edit: Seeing as this is all probably quite confusing, I’ve made a flowchart which displays how AdSweep is going to work. It’s available here.

Tags:

6 Responses to “AdSweep Online”

  • Brandon says:

    I am interested in testing this.

  • Kieran P says:

    Sure, I’ll give it a go.

  • ralphviktor says:

    I would be interested in testing.

  • Ryan R says:

    I would be happy to help test.

  • arienh4 says:

    @ilev: That’s because at the moment, it doesn’t use a background page, and therefore doesn’t have it’s own process. The next version will.

  • alexandrojv says:

    :D you know I’m up for it!

  • Leave a Reply

    Hi, I'm and I'd like to leave a comment.

    My email address is if you'd like to reach me.

    I also have a website which can be found at .

    Here's what I'd like to say: