Hacker News new | ask | show | jobs
by 3np 2119 days ago
NodeJS is single-threaded while Ruby has native threads and "fibers" - what makes you say you wouldn't be able to utilize additional cores in Ruby?
2 comments

Fibers are still restricted by the GVL. Threads are also restricted by the GVL. The only "true" concurrency in MRI is to fork a process.
You can. You can with Node too.

With Node you can just use workers. I have tools I wrote in Node that can max out my 16 core MacBook.

Some major differences here are how they interface with I/O and the mechanisms around memory sharing.

Nodejs workers are more like webworkers and mostly suitable for proper CPU-intensive parallelization whereas in Ruby it's not uncommon to run e.g. multithreaded web server in the same process and namespace.