Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Trello staying updated?

How does trello.com keep all the users screens updated with new information as it comes in?

For example, if I change something on my screen, it automatically changes on all the other users screen who are also on that page...Are they just constantly refreshing the page or is their something else going on?

like image 974
David19801 Avatar asked Jan 06 '12 10:01

David19801


2 Answers

Original Answer

Whilst I do not work for Trello, from the outside it looks like it is using AJAX polling to look for updates to the presented information from looking at the site in firebug.

You can also use Comet to achieve this.

Updated

So I have done a little more digging and I found this on Hacker News:

Trello does use Socket.io. If your browser supports websockets it will use them, but it will transparently fall back to polling if necessary. - posted by ianthehenry Link to post

And then later:

We're scaling back a little to handle the usage spike from the initial launch, so some users will get polling even if their browsers support websockets. As the load stabilizes, we'll be switching them back on and you should see performance improve quite a bit. - posted by ianthehenry Link to post

I can only assume that ianthehenry is working for FogCreek, but I am unable to confirm it.

He also goes on to mention some of the other projects they use with:

Express, Async, Mongoose, Redis, Socket.io, CoffeeScript, Less, and Underscore, off the top of my head. We also use Node Inspector during development; that's a great little tool. - posted by ianthehenry Link to post

Update Again

Trello themselves have just written a blog post confirming their stack: http://blog.fogcreek.com/the-trello-tech-stack/

like image 136
Treffynnon Avatar answered Oct 02 '22 05:10

Treffynnon


They use the http://socket.io/ - project that makes WebSockets and realtime possible in all browsers

like image 39
Pavel Machekhin Avatar answered Oct 02 '22 04:10

Pavel Machekhin