Sinar / popit_ng

Database and API implementation of Popolo standard
GNU Affero General Public License v3.0
22 stars 4 forks source link

Request stats for instances #212

Open kaerumy opened 8 years ago

kaerumy commented 8 years ago

A simple option to add in config file, google anlyatids or other anlyatics javascript to capture stats

kaerumy commented 8 years ago

I've bumped this up as a priority, because this is needed for capacity and funding planning.

sweemeng commented 8 years ago

Currently we will just count from nginx access log.

Might test using http_referer in log module to see if it works for http client that is not browser. http://nginx.org/en/docs/http/ngx_http_log_module.html

sweemeng commented 8 years ago
108.162.215.190 - - [30/Aug/2016:16:32:27 +0000] "GET /en/posts/55b7456366d0d137274e56f5 HTTP/1.1" 200 2889 "http://vue-babbageui-demo.netlify.com/" "Mozilla/5.0 (Windows NT 5.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2454.101 Safari/537.36

http referer only work for browser js client though, maybe

sweemeng commented 8 years ago
108.162.226.150 - - [28/Aug/2016:06:42:08 +0000] "GET /en/persons/545e44c75222837c2c058d88/ HTTP/1.1" 200 564 "-" "python-requests/2.6.0 CPython/2.7.6 Linux/4.6.3-x86_64-linode70"

Oops won't work if it is from server side script...