Giter VIP home page Giter VIP logo

emojitrack's Introduction

emojitrack

emojitrack tracks realtime emoji usage on twitter! it takes advantage of a number of technologies, notably the twitter streaming API, redis, SSE, and other good stuff.

Note: many of the components emojitrack uses have been carved out into independent open-source projects, see the following:

Development Setup

Full stack

  1. Make sure you have Ruby 2.0.0 installed (preferably managed with RVM or rbenv so that the .ruby-version for this repository will be picked up).

  2. Get the repository and basic dependencies going:

    git clone mroth/emojitrack
    cd emojitrack
    bundle install --without=production
    echo "RACK_ENV=development" >> .env
    
  3. Also in .env you'll then need to set the standard Twitter credentials for CONSUMER_KEY, CONSUMER_SECRET, OAUTH_TOKEN, OAUTH_TOKEN_SECRET. Requires credentials with an elevated track limit! If you don't have that, set MAX_TERMS to 400 or less.

  4. Make sure you have redis installed and running. The rules in lib/config.rb currently dictate the order a redis server instance is looked for.

  5. Run all processes via foreman start.

Be sure to note that while the processing power is fairly managable, the feeder component of emojitrack requires on it's own about 1MB/s of downstream bandwith, and ~250KB/s of upstream. You can use the MAX_TERMS environment variable to process less emoji chars if you don't have the bandwidth where you are.

Web only

You can do work on the web component only by utilizing the hosted production redis instance. First, follow the above steps for setting stuff up, but steps #1 and #2 only.

Then, set REDISTOGO_URL environment variable via .env to be the full URI of the production redis instance (get it from @mroth if you are a developer on this project).

Note, if you do this, DO NOT RUN THE FEEDER PROCESS as it will risk corrupting our production data, just run the web component only with foreman start web.

Production setup

For heroku:

heroku create --stack cedar --addons redistogo:nano memcachier:dev newrelic:standard hostedgraphite
heroku config:add RACK_ENV=production
heroku config:add CONSUMER_KEY=xxx CONSUMER_SECRET=yyy OAUTH_TOKEN=aaa OAUTH_TOKEN_SECRET=bbb

emojitrack's People

Contributors

mroth avatar jeffreytierney avatar

Stargazers

Murat Bastas avatar Angus H. avatar

Watchers

Erik Berlin avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.