Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/endor/aggregate
https://github.com/endor/aggregate
Last synced: 15 days ago
JSON representation
- Host: GitHub
- URL: https://github.com/endor/aggregate
- Owner: endor
- Created: 2015-04-27T17:09:30.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2015-04-28T18:23:40.000Z (over 9 years ago)
- Last Synced: 2023-03-10T21:57:26.790Z (over 1 year ago)
- Language: Ruby
- Size: 1.11 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# API
## Setup
gem install bundler
bundle install
createuser -d -P -e test
createdb --username=test -W --owner=test -e api_test
\copy ad_statistics FROM '/path/to/ad_statistics.tsv';
\copy ad_actions FROM '/path/to/ad_actions.tsv';## Run tests
rspec
## Run
ruby api.rb
## Optimize DB performance
* use replication and setup slaves (http://docs.memsql.com/docs/latest/admin/replication.html)
* release connection when done
* use database connection pooling (http://en.wikipedia.org/wiki/Connection_pool)
* might give VARCHAR a length or use INT for count/value
* hash index on ad_id, skip list index on date, descending