Home / Function/ EventExecutor() — netty Function Reference

EventExecutor() — netty Function Reference

Architecture documentation for the EventExecutor() function in AutoScalingEventExecutorChooserFactory.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  178c3324_6aa0_719a_b4ab_65660a5ce63c["EventExecutor()"]
  bb4797cf_7318_6bbb_4c87_1f53888dd980["AutoScalingEventExecutorChooser"]
  178c3324_6aa0_719a_b4ab_65660a5ce63c -->|defined in| bb4797cf_7318_6bbb_4c87_1f53888dd980
  a4304eb6_db6c_91df_93c2_2b3acb53fc85["tryScaleUpBy()"]
  178c3324_6aa0_719a_b4ab_65660a5ce63c -->|calls| a4304eb6_db6c_91df_93c2_2b3acb53fc85
  style 178c3324_6aa0_719a_b4ab_65660a5ce63c fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

common/src/main/java/io/netty/util/concurrent/AutoScalingEventExecutorChooserFactory.java lines 186–199

        @Override
        public EventExecutor next() {
            // Get a snapshot of the current state.
            AutoScalingState currentState = this.state.get();

            if (currentState.activeExecutors.length == 0) {
                // This is only reachable if minChildren is 0 and the monitor has just suspended the last active thread.
                // To prevent an error and ensure the group can recover, we wake one up and use the
                // chooser that contains all executors as a safe temporary choice.
                tryScaleUpBy(1);
                return allExecutorsChooser.next();
            }
            return currentState.activeExecutorsChooser.next();
        }

Domain

Subdomains

Frequently Asked Questions

What does EventExecutor() do?
EventExecutor() is a function in the netty codebase, defined in common/src/main/java/io/netty/util/concurrent/AutoScalingEventExecutorChooserFactory.java.
Where is EventExecutor() defined?
EventExecutor() is defined in common/src/main/java/io/netty/util/concurrent/AutoScalingEventExecutorChooserFactory.java at line 186.
What does EventExecutor() call?
EventExecutor() calls 1 function(s): tryScaleUpBy.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free