Java thread per connection model vs NIO

后端 未结 7 1441
悲&欢浪女
悲&欢浪女 2020-12-12 14:58

Is the non-blocking Java NIO still slower than your standard thread per connection asynchronous socket?

In addition, if you were to use threads per connection, would

相关标签:
7条回答
  • 2020-12-12 16:00

    If you do client side network calls, most likely you just need plain socket io.

    If you are creating server side technologies, then NIO would help you in separating the network io part from fulfillment/processing work. IO threads configured as 1 or 2 for network IO. Worker threads are for actual processing part(which ranges from 1 to N, based on machine capabilities).

    0 讨论(0)
提交回复
热议问题