2 ms·
Multithreading is achieved through workers and the event based architecture, it's not the same, but we should rather discuss the pros/cons of it.
by epolanski 3y ago
Multithreading is achieved through workers and the event based architecture, it's not the same, but we should rather discuss the pros/cons of it.
- bheadmaster 3y agoPros: Vertical scalability. Cons: All your async code becomes full of data races. I suppose adding multithreading to the Node ecosystem would be as hard (if not harder) than removing GIL from Python. At least Python has locking primitives. Node, as far as I know, has none.
- dvlsg 3y ago> Node, as far as I know, has none. Atomics are probably the closest. https://v8.dev/features/atomics https://v8.dev/features/atomics