Skip to content


websockets and mojito. when? #410

chetanankola opened this Issue · 5 comments

3 participants

Yahoo Inc. member

how and when do you think will mojito have support for websockets built into it?

if not is there a simple hack to integrate websockets into mojito?


Honestly, I just don't see a ton of demand for it at this point.
Can you tell us more about what you're doing and why you need WebSockets?


no response from @chetanankola, closing

@rwaldura rwaldura closed this

What is the correct way to feed several messages back to the client when the server is doing some heavy crunching and wants to periodically give feedback to the client in YUI?

With Websockets, you don't need to poll the server, nor does the server need to keep track of sessions etc. I currently have a scenario like this and need an answer.


Hi @ooskapenaar : can you implement an AJAX-based polling mechanism?
What kind of "heavy crunching" is your server doing? That's rarely the ideal use-case for Node.


Hi @rwaldura, well it's this is an admin front-end to a MongoDB based node app, which controls processes such as CSV imports. Now regardless of whether these are forked out, or performed via bash script, {or: whatever}, we want to be able to report on these processes in real time. As it is, I am starting these processes using Y.mojito.REST, but this doesn't offer websocket type functionality. And yes, I can implement polling, sure, because we only ever allow one CSV import at a time. However, I can imagine parallel scenarios, where parallel sessions would be polling and WebSockets would be an elegant solution to the session management hassle one would otherwise have.

To me node.js is not restricted by short or long process life times. As long as you can work asynchronously, node.js is a good fit. Isn't that right? The CSV import is fully asynchronous.


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.