Home / Function/ progress() — netty Function Reference

progress() — netty Function Reference

Architecture documentation for the progress() function in ChannelOutboundBuffer.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  292a6543_4b71_d410_0730_589bb8ddbf08["progress()"]
  509b1bc5_7cdc_9ee4_03d9_31eb2203d807["ChannelOutboundBuffer"]
  292a6543_4b71_d410_0730_589bb8ddbf08 -->|defined in| 509b1bc5_7cdc_9ee4_03d9_31eb2203d807
  0ede732b_f018_f649_0cfa_0293b2b30200["removeBytes()"]
  0ede732b_f018_f649_0cfa_0293b2b30200 -->|calls| 292a6543_4b71_d410_0730_589bb8ddbf08
  style 292a6543_4b71_d410_0730_589bb8ddbf08 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

transport/src/main/java/io/netty/channel/ChannelOutboundBuffer.java lines 250–268

    public void progress(long amount) {
        Entry e = flushedEntry;
        assert e != null;
        ChannelPromise p = e.promise;
        long progress = e.progress + amount;
        e.progress = progress;
        assert p != null;
        final Class<?> promiseClass = p.getClass();
        // fast-path to save O(n) ChannelProgressivePromise's type check on OpenJDK
        if (promiseClass == VoidChannelPromise.class || promiseClass == DefaultChannelPromise.class) {
            return;
        }
        // this is going to save from type pollution due to https://bugs.openjdk.org/browse/JDK-8180450
        if (p instanceof DefaultChannelProgressivePromise) {
            ((DefaultChannelProgressivePromise) p).tryProgress(progress, e.total);
        } else if (p instanceof ChannelProgressivePromise) {
            ((ChannelProgressivePromise) p).tryProgress(progress, e.total);
        }
    }

Domain

Subdomains

Called By

Frequently Asked Questions

What does progress() do?
progress() is a function in the netty codebase, defined in transport/src/main/java/io/netty/channel/ChannelOutboundBuffer.java.
Where is progress() defined?
progress() is defined in transport/src/main/java/io/netty/channel/ChannelOutboundBuffer.java at line 250.
What calls progress()?
progress() is called by 1 function(s): removeBytes.

Analyze Your Own Codebase

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

Try Supermodel Free