Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Simple Group Chat built with Faye at a Toronto Ruby Hack Night
Ruby JavaScript
branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
app
config
db
doc
lib
public
script
test
vendor/plugins
.gitignore
Gemfile
Gemfile.lock
README.rdoc
Rakefile
config.ru
faye.ru
interceptor.ru

README.rdoc

Faye Messaging

A simple Group Chat application written during the April 28th Toronto Ruby Hack Night.

The goal was to create a real time web application using Rails and Faye.

Feel free to browse the source and commit history to get a feel for how it works so you can use it in your own app.

We all learnt a lot by developing this app and it was a very successful Hack Night!

May 12th Hack Night

We started to extend the app to look for ISBN numbers through Amazon's API.

The purpose was to experiment with Event Machine for it's asynchronous non-blocking support, as suggested by Ian Ha.

We also added Faye channels to prevent XSS attacks from chat messages and made the app look nicer.

Once again, it was an excellent learning experience using advanced concepts which we can all take and use in our everyday apps!

The app is currently a work in progress, therefore the Setup and Implementation sections will be updated once it is finalized. Feel free to look at source code until then.

Setup

Execute this line from the app's root directory to run Faye:

rackup faye.ru -s thin -E production

In order to run on anything but localhost, change the IP in the file /config/faye.yml, and don't forget to also run one of the files in the /lib folder; like so:

ruby bayes_classifier.rb

Notes on Implementation

Click on the “Sign in with Twitter” link to set your Username to your Twitter Username.

You can also enter your Username in the Text Field if you haven't signed in with Twitter.

Pressing the “Up” and “Down” arrow keys on the keyboard when the Message Text Box is in focus will traverse through your history of sent messages (like your Terminal).

Contributors

  • Tasveer Singh (@tazsingh)

  • Dann Toliver (@dann)

  • Aaron McLeod (@agmcleod)

  • Alex Chesser (@fstrnet)

  • Nick Hoffman (@nphoffman)

May 12th Hack Night

  • Ian Ha (@ianpha)

  • Victor Stan (@victorbstan)

  • Morgan Tocker (@morgo)

Feel free to extend this app and send me pull requests!

Something went wrong with that request. Please try again.