7 ms·
Balloons.io: an awesome looking realtime chat on node.js
- DigitalSea 14y agoI've yet to use Node.JS for anything yet even though I want too, it looks like Node.JS is only being used for analytics and chat applications is that all it is capable of or are people not fully using the power of Node? Balloons.io is a beautifully designed chat app, better than that of any other Node chat demo I've seen, nice one.
- aaronblohowiak 14y ago>it looks like Node.JS is only being used for analytics and chat applications is that all it is capable of or are people not fully using the power of Node? Node is still immature, so it makes sense to use it in spite of the relative roughness only when it has a distinct advantage over other available technologies. Its ecosystem has also streamlined the building of server-push apps. You can use node/express in lieu of rails or django, but it doesn't offer anything particularly interesting here. Analytics and chat apps tend to be built on persistent servers that have long-running stateful sessions, which the node ecosystem has focused on making easy... you could use EM or Twisted or Netty, but they aren't as shiny / low barrier to entry. So, we are seeing people take advantage of the comparable strengths of a new technology that makes certain apps easier to build.
- phillmv 14y agoYou use the right tool for the task at hand. Node is only notably useful for a relatively narrow range of applications. For everything else, you'd much better served by using Django/Rails/etc.
- jQueryIsAwesome 14y agoAnd you know... streams, which allow you to easily makes bridges between software and HTTP requests; so you can make video encoding in real time (while is being uploaded) just using node + ffmpeg; or you could process a text file content at the same time is being uploaded (perhaps a database backup?) or you could quickly set up a proxy that doesn't have to store the files.
- blantonl 14y agoWe use node.js as an API/ajax delivery server. It fits well in this realm for us.
- TazeTSchnitzel 14y agoWhat does "Twitter based" mean? It uses Twitter for authentication? Or it uses bootstrap? Or tweets?
- pssdbt 14y agoAuthentication it sounds like: "Balloons uses easy-OAuth for authentication with twitter. You can easily change this code to authenticate with Facebook, for example, lets with Facebook."
- ajays 14y agoHow scalable is this? I would think it's easy to put together something that serves, say, 100 users simultaneously. But how well does this scale to 100K users?
- phillmv 14y ago>But how well does this scale to 100K users? It wouldn't. Designing a system to handle 100k simultaneous users is hard, and a problem few people suffer from. Why would you ask this question?
- blantonl 14y agoWhy would you ask this question? Because maybe he is looking to develop a chat system that can scale to 100,000 users? There are many instances where someone is tasked to look at a technology and understand how it scales. Frankly, it would be helpful for you to tell us how "It wouldn't"
- phillmv 14y agoBecause the order of magnitude is insane. It's a) not a common problem, and b) is obviously non trivial with current technology. The bandwidth necessary for 100k users would saturate many a pipe, and would immediately require more than one commoditized machine. It's like saying "That's a cute little Prius you got there. How many semi trailers can it pull?"
- ericmoritz 14y agoIn my experience, a single node web socket server has trouble with 5,000 concurrent connections nonetheless 100,000 connections.
- factorialboy 14y agoNo reason why it can't scale. Spawn up more processes, load balance.
- 14y ago
- chetan51 14y agoThis could totally use a live demo.
- rglullis 14y agoYes. But every chat application in node.js that has ever been presented in HN faced the same fate of being brought down to a crawling pulp whenever it had more than 100 or so concurrent users.
- mickeyp 14y agoWhich is a bit amusing, as I remember standalone IRC servers handling 40,000+ peak users with relative ease -- and that was back in the late 90s on commodity server hardware.
- will_work4tears 14y agoThis makes me wonder, what is the difference in technologies? I never used IRC to be honest, was it downloadable software or was it web based? (I'm not that young I swear, I'll be 35 next week - I just didn't do chat)
- moe 14y agoNo need for the past tense, IRC is very alive! Popular GUI-clients would be Colloquy on Mac, mIRC on windows and XChat on linux. Just download one and see for yourself; Freenode is a popular network for hackers of all kinds, QuakeNet is the network for gamers (and also happens to be the biggest with ~60k users online at any given time).
- hogu 14y agoyou can also get support for many open source projects on their respective irc channels, most of them are on irc.freenode.net
- mickeyp 14y agoIt's just done well. It has stood the test of time, and seen nearly 30 years of development in multiple, competing irc server products. A lot of rivalry and different views and attitudes to certain strategies. IRC is amazing. Servers are linked as leaves to hubs, or as hubs, linking to other hubs or leaves. If the network splits (one server goes down, breaking the tree) it can be quickly relinked to secondary or tertiary servers, restoring connectivity. For its time, and even to this day, it is an impressive protocol that is not only fairly easy to implement from a client perspective, but a very scalable chat server architecture.
- fratis 14y agoThe readme isn't very well written. Would someone with Node.js/redis experience be willing to write a more comprehensive installation guide?
- rjsamson 14y agoMy first thought was 'oh, another node.js chat app...', but I have to say, the design is really slick - very cool.
- rjsamson 14y agoOh - and they might want to add .DS_Store to .gitignore :)
- pssdbt 14y agoLive demo up here if anyone else was curious: http://www.pssdbt.com:3000 http://www.pssdbt.com:3000 If you want to run it yourself on a public-facing server, you'll need to change the connection to Socket.IO on line 2 of /public/js/script.js to point to your server instead of localhost. I also had to edit /views/themes/default/room_list.jade and put the 'each room,key in rooms' bit inside of an 'if rooms' statement because that was throwing an error. Also worth noting, nothing is filtered (you can send <script> tags for example and they'll run for everyone).
- fratis 14y agoIt's also throwing a 404 error for modernizr. It's looking for it in /rooms/js/libs/modernizr..., but it's actually in /js/libs/modernizr.... This'd all be easier to confirm, obviously, if they'd have set up a demo site. Anyone else care to take a gander?
- pssdbt 14y agoThat's because they were using a relative reference, fixed it.
- halayli 14y agoThe challenge in chat is really scalability. I see no mention about this. How will it scale on 10 servers? The UI is well executed.
- a_macgregor 14y agoFound an interesting bug, you can inject JS code ... give it a try on http://www.pssdbt.com:3000 http://www.pssdbt.com:3000 demo Just type <script>alert('JS Injection for the win');</script> on the chat box, it will execute for all members in the chat.
- ricardorauch 14y agoWe fixed it!
- a_macgregor 14y agoAwesome