News for hackers. Stuff that matters.
Re:Show HN: Wsq – WebSocket task queues by k__ on Wednesday December 09, 2015 @06:30AM (#10703078)
Do I understand this correctly.

This is some "on the fly" computation?

Like, people could add computing power to a process just by surfing to a webpage?

Re:Show HN: Wsq – WebSocket task queues by rwinn on Wednesday December 09, 2015 @06:50AM (#10703118)
Not exactly, it is a task queue that allows workers to be run in the browser.

If you could break your problem up in to lots of small isolated tasks it could be used like that

Re:Show HN: Wsq – WebSocket task queues by stygiansonic on Wednesday December 09, 2015 @06:51AM (#10703121)
Based on a quick inspection (WS opened, binary frames going over it, and CPU utilization), this appears to be the case.

A very interesting way to do distributed computing!

Re:Show HN: Wsq – WebSocket task queues by rwinn on Wednesday December 09, 2015 @07:06AM (#10703159)
Btw, if anyone is wondering why the workers run so slow when in a background tab, it is because most browsers throttle setTimeout's to run max once a second when the browser window looses focus. (web workers does not have this problem but for the demo i figured it would be fun to watch the workers do their thing)
Re:Show HN: Wsq – WebSocket task queues by poseid on Wednesday December 09, 2015 @10:55AM (#10704337)
is this something like dnode? I used dnode for RPC style programming between an Arduino and web server: https://github.com/embeddednodejs/ch_8_entering_the_cloud/bl...

possibly your lib could make the setup nicer.

Re:Show HN: Wsq – WebSocket task queues by poseid on Wednesday December 09, 2015 @10:58AM (#10704370)
also, how would you add custom events to the tasks, e.g. process data from a "button", "slider", ...
Re:Show HN: Wsq – WebSocket task queues by forgotmypassw on Wednesday December 09, 2015 @06:49AM (#10703116)
The animation makes the browser tab so jaggy I can barely scroll down to read more.
Re:Show HN: Wsq – WebSocket task queues by rwinn on Wednesday December 09, 2015 @07:54AM (#10703299)
Found the problem and pushed a fix, should me much smoother now.

It was Firefox's SVGPathElement::getPointAtLength implementation that was slow, working around it by caching all the calls to it.

Re:Show HN: Wsq – WebSocket task queues by rwinn on Wednesday December 09, 2015 @06:52AM (#10703122)
That sucks. I'm using d3.js to animate svg elements, runs smoothly on my machine, what browser/os are you on?
Re:Show HN: Wsq – WebSocket task queues by forgotmypassw on Wednesday December 09, 2015 @06:54AM (#10703127)
FF Nightly on Windows, I also checked on my laptop running Linux and the same thing happens so I guess it's related to the browser specifically.
Re:Show HN: Wsq – WebSocket task queues by rwinn on Wednesday December 09, 2015 @07:00AM (#10703143)
Yep, I can reproduce it on OS X with FF 42.0 as well. Going to see if i can find what's causing the low framerate.
[dead]
Re:Show HN: Wsq – WebSocket task queues by Gigablah on Wednesday December 09, 2015 @07:46AM (#10703277)
You might want to check out what's causing your constipation.
Re:Show HN: Wsq – WebSocket task queues by fulafel on Wednesday December 09, 2015 @07:19AM (#10703193)
On Ubuntu it's fast in Chrome and slow in Firefox.
Re:Show HN: Wsq – WebSocket task queues by thesorrow on Wednesday December 09, 2015 @01:02PM (#10705421)
Are you using libchan js implementation jschan to multiplex streams ?
Re:Show HN: Wsq – WebSocket task queues by rwinn on Thursday December 10, 2015 @08:20AM (#10710445)
No I'm using https://github.com/maxogden/multiplex

Didn't know about jschan, would be interesting to see a performance comparison between the two.