NOTE

Netty Source: Creating NioEventLoop Children

Creation of the event-loop child set and channel-to-event-loop selection in a NioEventLoopGroup.

JavaCreated Updated 1 min readhistorical

This is a historical learning note and may contain outdated or incomplete understanding.

A NioEventLoopGroup owns a collection of child NioEventLoops. Each child maintains selector/task-processing state; the group chooses a child when a channel is registered.

Once registered, keeping a channel on one event-loop thread provides ordering/thread-confinement guarantees for channel events.

Do not depend on a particular array shape, default child count, or chooser algorithm from an old source version. Those are tuning/implementation details rather than Netty API semantics.

Loading helpful count