Saturday, January 10, 2009

Inside AdSense: Behind the scenes of scheduled maintenance

We know many of you have questions about what we work on during our monthly scheduled maintenance and how this work affects you. As one of the engineers who's involved with this AdSense maintenance, I'd like to provide some insight into what goes on during these periods.

First, you're probably used to hearing us say that maintenance won't affect your ad serving, and that your earnings will still be tracked as normal. Here's why: when someone visits your site, one of our many ad servers decides which ads we'll show on your pages, and we log the fact that we delivered those ads to your site. We use this information to calculate the number of ad impressions your site visitors generated. Likewise, any clicks on those ads get logged by another of our ad servers. These servers operate independently, so as we roll out upgrades, we can update groups of ad servers without impacting overall ad serving or our internal logs.

Reporting, on the other hand, is quite a different issue, and this is why you aren't able to access your account during maintenance periods. The stats logged by our ad servers aren't immediately reflected in your reports, as they need to be collected and tallied in one place before we can give you a single summary of your ad impressions, clicks, and earnings. Our systems diligently work around-the-clock to collect this data from our many ad servers and tally it all up for each publisher, generally updating the reports with recent stats every 15 to 30 minutes.

Although many of our software upgrades occur throughout the month without any noticeable impact to you, certain types of reporting upgrades just aren't practical to perform on-the-fly. When we perform our monthly maintenance, we have a chance to put this reporting collection on hold for these big upgrades. This lets us upgrade our databases, prepare our systems for new features, and perform the necessary tasks needed to keep a complex system like this one running smoothly.

Some of you have noticed that impression and click stats appear a bit low after we bring the AdSense site back online, wondering if maybe AdSense maintenance is used to change data to affect your earnings. That's a theory I'm happy to debunk: this discrepancy is actually a reporting artifact, occurring because we pause stats tallying during our maintenance period. After resuming, our reporting systems have to digest all of the accumulated impression and click logs, and there's a lot of data! It takes the reporting systems a little while to process the logs, but rest assured that once we get the chance to catch up, the reports will reflect all of the impressions, clicks, and earnings that occurred during the maintenance period. If you're concerned about the stats you're seeing, we recommend checking back throughout the day as your reports are updated.

I hope this explanation provides a better picture of what we're doing during these maintenance periods. Though I do have to work the occasional Saturday, it's worth it to make sure your stats are accurate and everything's working smoothly. (Hey, at least it gives me the chance to sing cheesy 80's pop music in the office to my heart's content without disturbing too many other engineers!)

Posted by Curtis Light - AdSense Software Engineer

No comments: