Getting the number of downloads of a specific S3 object

I have several S3 objects available to my clients. Since I would like to pay my customers for use, I wondered if there is any smart way to get the number of times this file was downloaded?

Alternatively, I suppose I could parse the log files provided by S3, but with 10m + samples for each client, this could be a task bit.

Any ideas?

+3
source share
3 answers

If you allow them to download via HTTP, you can use the URL shortening service to redirect to your file (e.g. goo.gl). I believe that they can handle the load, and they also provide some nice stats along with common clicks.

+1
source

You can redirect through a script to your website, which increments the account before being redirected to the S3 URL.

0
source

, , node.js Couchbase. , HTTP 200s , hitcount ( ), HTTP 206.

0

Source: https://habr.com/ru/post/1749720/


All Articles