Skip to content
Advertisement

Tag: parallel-processing

Is console.log atomic?

The print statement in Python is not thread-safe. Is it safe to use console.log in Node.js concurrently? If so, then is it also interleave-safe? That is, if multiple (even hundreds) of callbacks write to the console, can I be sure that the output won’t be clobbered or interleaved? Looking at the source code, it seems that Node.js queues concurrent attempts

Advertisement