Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

playground for playing with various stuff... lots of tweets, lots of ways to store and process them

branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 redis
Octocat-spinner-32 resque_jobs
Octocat-spinner-32 .gitignore
Octocat-spinner-32 README.md
Octocat-spinner-32 Rakefile
Octocat-spinner-32 credentials.yml.sample
Octocat-spinner-32 fetcher.rb
Octocat-spinner-32 geostats.rb
Octocat-spinner-32 reinjector.rb
README.md

Twootr!

Introduction

Twootr! is my playground to learn about some technologies that the cool kids have been playing with. I've wanted to learn more about messaging systems and large dataset management, so when someone told me about some example code that ships with yajl-ruby that fetches tweets from Twitter's Streaming API, I decided that would be a really solid data source.

Over time, I'll be experimenting with queueing tools like ActiveMQ, RabbitMQ, and Resque, data storage systems like PostgreSQL, CouchDB, MongoDB, and Redis.

I'm also interested in playing with Hadoop and similar data manipulation tools down the road.

Current Status

Iteration One: It used to be that the twoots would go directly into an unstructured postgres table with a couple of flags to note whether they'd been put into CouchDB or MongoDB yet. This got untenable, as every time I wanted to add a new storage backend, I needed to add a new flag column. With 10 million records, that took forever.

Iteration Two: So, I've moved to a queueing system. Now the twoots come straight off the API into a queue called "intake". This allows us to remove some non-twoot API responses before persisting to the backends. It also has the side benefit of removing the fetcher's need to know what storage backends we're using... another process will come by later and take care of putting the twoots into queues for the storage backends.

Next Up: Explore using RabbitMQ's fanout exchanges so a message can be published and appear in each of the backend queues.

The MIT License

Copyright (c) 2010, Ben Bleything ben@bleything.net

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Something went wrong with that request. Please try again.