Single thread per App instance of a cap node.js

Sorry about this stupid question, but I just wanted to get confirmation that my understanding is correct..

When providing a cap based service that is built with node.js, is there only one thread available to handle this request? I.e. If I have a long running service handler this blocks/queues any other caller of this service until it is completed.

And thus if I want multiple requests of that cap service, I need to spawn a second instance of the app?

Was making a test with a forced loop in the on-handler of am action and while this was running, triggered a second call of this action. It shows that this is only processing the second request if the first one left the loop. If I add a second instance of the app, it does immediately process a second request.

And would a similar cap service built with the java Version support multiple threads per one instance? And of so how many and how is this controlled?

Read more here: Source link