EventLoop which uses kqueue under the covers. Only works on BSD!
| Modifier and Type | Field and Description |
|---|---|
| private final boolean | |
| private final KQueueEventArray | |
| private final IntObjectMap | |
| private final KQueueEventArray | |
| private volatile int | |
| private final IovArray | |
| private static final int | |
| private static final int | |
| private final FileDescriptor | |
| private static final InternalLogger | |
| private final IntSupplier | |
| private final SelectStrategy | |
| private static final AtomicIntegerFieldUpdater | |
| private volatile int |
| Access | Constructor and Description |
|---|---|
| pack-priv | KQueueEventLoop(EventLoopGroup parent, Executor executor, int maxEvents, SelectStrategy strategy, RejectedExecutionHandler rejectedExecutionHandler, EventLoopTaskQueueFactory taskQueueFactory, EventLoopTaskQueueFactory tailTaskQueueFactory)
|
| Modifier and Type | Method and Description |
|---|---|
| pack-priv void | |
| pack-priv IovArray | |
| protected void | cleanup()
Overrides io. |
| private void | |
| pack-priv void | |
| public int | |
| private static void | |
| private int | |
| private int | |
| private int | |
| private static Queue | |
| protected Queue | newTaskQueue(int maxPendingTasks)
Overrides io. Queue which will holds the tasks to execute.
|
| private static Queue | |
| private void | |
| public int | registeredChannels()
Overrides io. Channels registered with this EventLoop or -1
if operation is not supported.
|
| public Iterator | |
| pack-priv void | |
| protected void | run()
Implements abstract io. taskQueue
|
| public void | setIoRatio(int ioRatio)
Sets the percentage of the desired amount of time spent for I/O in the event loop. |
| protected void | |
| private void |
| allowGrowing | back to summary |
|---|---|
| private final boolean allowGrowing | |
| changeList | back to summary |
|---|---|
| private final KQueueEventArray changeList | |
| channels | back to summary |
|---|---|
| private final IntObjectMap<AbstractKQueueChannel> channels | |
| eventList | back to summary |
|---|---|
| private final KQueueEventArray eventList | |
| ioRatio | back to summary |
|---|---|
| private volatile int ioRatio | |
| iovArray | back to summary |
|---|---|
| private final IovArray iovArray | |
| KQUEUE_MAX_TIMEOUT_SECONDS | back to summary |
|---|---|
| private static final int KQUEUE_MAX_TIMEOUT_SECONDS | |
| KQUEUE_WAKE_UP_IDENT | back to summary |
|---|---|
| private static final int KQUEUE_WAKE_UP_IDENT | |
| kqueueFd | back to summary |
|---|---|
| private final FileDescriptor kqueueFd | |
| logger | back to summary |
|---|---|
| private static final InternalLogger logger Hides io. | |
| selectNowSupplier | back to summary |
|---|---|
| private final IntSupplier selectNowSupplier | |
| selectStrategy | back to summary |
|---|---|
| private final SelectStrategy selectStrategy | |
| WAKEN_UP_UPDATER | back to summary |
|---|---|
| private static final AtomicIntegerFieldUpdater<KQueueEventLoop> WAKEN_UP_UPDATER | |
| wakenUp | back to summary |
|---|---|
| private volatile int wakenUp | |
| KQueueEventLoop | back to summary |
|---|---|
| pack-priv KQueueEventLoop(EventLoopGroup parent, Executor executor, int maxEvents, SelectStrategy strategy, RejectedExecutionHandler rejectedExecutionHandler, EventLoopTaskQueueFactory taskQueueFactory, EventLoopTaskQueueFactory tailTaskQueueFactory) | |
| add | back to summary |
|---|---|
| pack-priv void add(AbstractKQueueChannel ch) | |
| cleanArray | back to summary |
|---|---|
| pack-priv IovArray cleanArray() Return a cleared | |
| cleanup | back to summary |
|---|---|
| protected void cleanup() Overrides io. Doc from io. Do nothing, sub-classes may override
| |
| closeAll | back to summary |
|---|---|
| private void closeAll() | |
| evSet | back to summary |
|---|---|
| pack-priv void evSet(AbstractKQueueChannel ch, short filter, short flags, int fflags) | |
| getIoRatio | back to summary |
|---|---|
| public int getIoRatio() Returns the percentage of the desired amount of time spent for I/O in the event loop. | |
| handleLoopException | back to summary |
|---|---|
| private static void handleLoopException(Throwable t) | |
| kqueueWait | back to summary |
|---|---|
| private int kqueueWait(boolean oldWakeup) throws IOException | |
| kqueueWait | back to summary |
|---|---|
| private int kqueueWait(int timeoutSec, int timeoutNs) throws IOException | |
| kqueueWaitNow | back to summary |
|---|---|
| private int kqueueWaitNow() throws IOException | |
| newTaskQueue | back to summary |
|---|---|
| private static Queue | |
| newTaskQueue | back to summary |
|---|---|
| protected Queue Overrides io. Doc from io. Create a new
| |
| newTaskQueue0 | back to summary |
|---|---|
| private static Queue | |
| processReady | back to summary |
|---|---|
| private void processReady(int ready) | |
| registeredChannels | back to summary |
|---|---|
| public int registeredChannels() Overrides io. Doc from io. Returns the number of
| |
| registeredChannelsIterator | back to summary |
|---|---|
| public Iterator Overrides io.
| |
| remove | back to summary |
|---|---|
| pack-priv void remove(AbstractKQueueChannel ch) throws Exception | |
| run | back to summary |
|---|---|
| protected void run() Implements abstract io. Doc from io. Run the tasks in the
| |
| setIoRatio | back to summary |
|---|---|
| public void setIoRatio(int ioRatio) Sets the percentage of the desired amount of time spent for I/O in the event loop. The default value is
| |
| wakeup | back to summary |
|---|---|
| protected void wakeup(boolean inEventLoop) Overrides io.
| |
| wakeup | back to summary |
|---|---|
| private void wakeup() | |