Home / Function/ consumer() — netty Function Reference

consumer() — netty Function Reference

Architecture documentation for the consumer() function in RecyclerBenchmark.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  f18b7e9e_82f1_c032_3601_48d2e21b42b0["consumer()"]
  f3ce3bf7_0aec_591c_d35b_cfe2adfbfa83["RecyclerBenchmark"]
  f18b7e9e_82f1_c032_3601_48d2e21b42b0 -->|defined in| f3ce3bf7_0aec_591c_d35b_cfe2adfbfa83
  251fa3e7_b8a3_3bc3_61c3_704e8ee32dcb["recycle()"]
  f18b7e9e_82f1_c032_3601_48d2e21b42b0 -->|calls| 251fa3e7_b8a3_3bc3_61c3_704e8ee32dcb
  style f18b7e9e_82f1_c032_3601_48d2e21b42b0 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

microbench/src/main/java/io/netty/microbench/util/RecyclerBenchmark.java lines 144–159

    @Benchmark
    @Group("producerConsumer")
    @BenchmarkMode(Mode.Throughput)
    @OutputTimeUnit(TimeUnit.MICROSECONDS)
    public void consumer(ProducerConsumerState state, Control control, ConsumerStats stats) throws Exception {
        Queue<DummyObject> queue = state.queue;
        DummyObject object;
        do {
            object = queue.poll();
            if (object != null) {
                object.recycle();
                return;
            }
            stats.emptyQ++;
        } while (!control.stopMeasurement);
    }

Domain

Subdomains

Calls

Frequently Asked Questions

What does consumer() do?
consumer() is a function in the netty codebase, defined in microbench/src/main/java/io/netty/microbench/util/RecyclerBenchmark.java.
Where is consumer() defined?
consumer() is defined in microbench/src/main/java/io/netty/microbench/util/RecyclerBenchmark.java at line 144.
What does consumer() call?
consumer() calls 1 function(s): recycle.

Analyze Your Own Codebase

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

Try Supermodel Free