adobe/brackets-registry — pull request #58 by ingorichter (2014-08-08 16:51:52+00:00)
Title: Fix download count inaccuracies in extension registry

This PR will fix
- https://github.com/adobe/brackets/issues/8402
- https://github.com/adobe/brackets/issues/8232
- https://github.com/adobe/brackets/issues/8231

There are two fixes in the PR

1. Existing recent download numbers have not been considered when the count was updated. Let's say the recent downloads for `20140807` have been `5`. Adding more downloads to this datapoint has overwritten the existing value. Now it gets properly added.
2. Downloading the log files from S3 happens incrementally. To make this work, after every log file download, the Key/ID of the last downloaded log file is stored for the next run. The next time the log files will be downloaded, the Key/ID will be used to download only files that have been created after the file denoted by the Key/ID. There was a bug in determining this Key/ID for the next run. This value got never updated since May, and this means that with every log file download, all files since then have been downloaded again and the data has been used to update the extension download count. This led to massive inflation of the download numbers.