2

This is a purely human problem and very likely a problem on my end.

We have a developer who every time Javascript is brought up emphasizes that it's single threaded on the server.

Is there a better phrase to describe Javascript single-threaded nature of having multi-threading implemented in libraries? I use the phrase multi-threading to only refer to when a user can create threads in user space (pthread_create for example) but I really dislike the idea of calling JS single-threaded (speaking of node here).

Words like concurrency or parallel are more problematic IMHO. Not looking for a long discussion of the nature but are there any suggestions to how to describe this? I think calling JS single-threaded is correct but is there another term? like lib-threaded or something? Maybe single-threaded non-blocking but too verbose.

timpone
  • 19,235
  • 36
  • 121
  • 211
  • 1
    This question appears to be off-topic because it is about semantics and wording and not a code problem. – j08691 Aug 13 '13 at 18:46
  • 2
    Calling JavaScript single-threaded is correct, thinking about it in any other terms in problematic and can lead to designs that only look efficient. Now criticizing JavaScript for being single threaded is also misguided. – Jason Sperske Aug 13 '13 at 18:47
  • 9
    maybe better suited for http://programmers.stackexchange.com/ ? – 1252748 Aug 13 '13 at 18:47
  • @j08691 I consider this a software problem and hence a development problem. – timpone Aug 13 '13 at 18:47
  • @timpone - I'm sure you do, however SO isn't the best place to ask this question. – j08691 Aug 13 '13 at 18:48
  • 3
    JavaScript is **evented**. – Bergi Aug 13 '13 at 18:52
  • just reread ?, could certainly migrate to programmers.stackexchange.com. I don't think I can – timpone Aug 13 '13 at 18:53
  • I like evented as a description thx Bergi – timpone Aug 13 '13 at 18:55
  • others: "event-driven", "event based" programming. related post mentioning possible multithreading using webworkers: http://stackoverflow.com/questions/39879/why-doesnt-javascript-support-multithreading – metadings Aug 13 '13 at 18:57
  • I call it bean-threaded – Ray Cheng Aug 13 '13 at 19:02
  • 1
    sounds like your co-worker is the one who is single-threaded. that's like complaining that cars need fuel... – dandavis Aug 13 '13 at 19:04
  • desptite the comments I still think there should be another terms to reflect this - like I say in the original question, the issues isn't whether or not JS is multithreaded but that I think there should be a way to accurately reflect this in language. – timpone Aug 13 '13 at 22:44

0 Answers0