I have a simple code for a multi-threaded echo server in Java (it returns whatever received back to the clients). I\'m profiling various resources of the server including the th
I'm not sure what you use to receive those connections, but usually frameworks that handle TCP connections non-blocking like Netty use a master thread to listen to the port and a thread pool to handle incomming connections. This means it will at least open 2 threads for the incomming connection if the thread-pool is limited to 1 thread.
See this example from the netty page, where 2 NioEventLoopGroups are used while bootstrapping the server.
The 2 threads are necessary to not block incoming traffic.