Browserver: a node.js HTTP server, in your browser
browserver.org
browserver.org
The title "node.js HTTP server, in your browser" is because the HTTP handler in the client (browser) has a Node-like API, see:
I put browserver together in my free time over the last week. It's still a bit of a toy, but I think it's useful to explore ideas around extending webhooks all the way to the browser, to simplify our increasingly complicated web architectures.
It's already late here in Tokyo, but I'll be up for a bit if anyone wants to chat/brainstorm about approaches like this (and also to make sure the server stays up).
On a related note, keep at it. I hope you go places.
And where/how did you get the idea?
Things like this make me wonder why I'm not having fun creating neat (and useful!) things.
Keep on being awesome. :)
It's also a very neat way to bring WebKit Inspector to bear on server style code. Glad you did it! I presume that you have a wildcard subdomain at the DNS level and then some Node parsing magic to correctly proxy. Why subdomains though? Why not just a tag like browserver.com/29adfija02 ?
How is it different, in practice, from say running a Node.JS on localhost and using localtunnel?
I've decided to try to get authors of similar tools together on a mailing list to discuss whether we can agree on a common protocol so our clients/servers (connectors/relays, backends/frontends) can be interoperable. Join us: http://mailman.klaki.net/mailman/listinfo/revprotun
The browser is still running its original js engine with none of the Node goodies. It merely receives proxied requests, does some stuff to it, then sends it back to the proxy, which returns it to the client.
It merely receives proxied requests, does some stuff to it, then sends it back to the proxy, which returns it to the client.
You just described the majority of the web servers that we web developers deal with. Sure, it's a proxy, but the fact that the machine responding is connected via WebSocket and not a local network doesn't make it any less of a server, in my opinion.You just listen for a URL and forward it to the browser with socket.io (Pusher, Pubnub are some commercial services for this)
If I can change some content in your webpage by just curling localhost, I can judge the title you put :)
Apparently there's a newer variation at:
https://addons.mozilla.org/en-US/firefox/addon/browser-server/
and of course there's Opera's Unity.I do get that the idea is that it "just" uses javascript (the server appears to be down, so I'm actually guessing) -- but when such projects already exist, I kind of expected more...
Unfortunately Chrome's native client(NaCl) does not support TCP yet! So I think something like this impossible in chrome? Any ideas?
Chrome has a JS socket API for extensions as well, but it doesn't currently support TCP listening.
Now, what's the project that will fully take advantage of this kind of thing?
I see the Unity approach being popularise via social networking (https://alicious.com/opera-about-to-change-the-world/) enabling users to retain control over their data and shop for suppliers to present a front-end to unify the data-streams of their associates.
That said, this is cool!
Change some HTML in that text area and refresh automatically in all listeners.
That would be an interesting toy to play for a while.
Could you share some traffic/load numbers from getting HN'ed?
Let me get back to you once the dust settles, deal?
Loading the app... If this message doesn't go away within 10 seconds, it means that the server crashed under heavy load. Please refresh mercilessly.
:)
It was a good 15 minutes, though.