I will soon be using a server named Undertow. The website says:
Undertow is a flexible performant web server written in java,
providing both blocking and non-blocking API’s based on NIO
Undertow is based on the JBoss XNIO library and like Nodejs, XNIO relies on operating system capabilities (epoll or kqueue when available) to be notified for IO events (when data is available to read from a socket for example).
In Undertow, accepting incoming requests is done following this model, by the
IO threads. Doing blocking operations on these threads would mean delaying the handling of new incoming requests. See Undertow's documentation on IO threads
Next to the IO threads, Undertow manages another thread pool, the
Worker threads, to handle blocking tasks (think of tasks like calling a webservices or querying a database.) And this is what you wont get with Nodejs!
To use a Worker thread, the request handling has to be dispatched from the IO thread. The API is comprehensive and easy to use, again, see Undertow's documentation, as a starting point.