Home / Function/ channelRead() — netty Function Reference

channelRead() — netty Function Reference

Architecture documentation for the channelRead() function in ProxyHandler.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  f71d1b6f_991f_8b73_bb78_675b65214707["channelRead()"]
  3f5c9c39_cf82_6deb_e43b_1a9ad5499a99["ProxyHandler"]
  f71d1b6f_991f_8b73_bb78_675b65214707 -->|defined in| 3f5c9c39_cf82_6deb_e43b_1a9ad5499a99
  ee7b6f57_8194_7877_f330_09c737f43af5["handleResponse()"]
  f71d1b6f_991f_8b73_bb78_675b65214707 -->|calls| ee7b6f57_8194_7877_f330_09c737f43af5
  cb0b2332_f25d_1f61_9378_a90a595d13ac["setConnectSuccess()"]
  f71d1b6f_991f_8b73_bb78_675b65214707 -->|calls| cb0b2332_f25d_1f61_9378_a90a595d13ac
  e5452aa5_fc3e_4478_6f1c_39e017cd9292["setConnectFailure()"]
  f71d1b6f_991f_8b73_bb78_675b65214707 -->|calls| e5452aa5_fc3e_4478_6f1c_39e017cd9292
  style f71d1b6f_991f_8b73_bb78_675b65214707 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

handler-proxy/src/main/java/io/netty/handler/proxy/ProxyHandler.java lines 246–269

    @Override
    public final void channelRead(ChannelHandlerContext ctx, Object msg) throws Exception {
        if (finished) {
            // Received a message after the connection has been established; pass through.
            suppressChannelReadComplete = false;
            ctx.fireChannelRead(msg);
        } else {
            suppressChannelReadComplete = true;
            Throwable cause = null;
            try {
                boolean done = handleResponse(ctx, msg);
                if (done) {
                    setConnectSuccess();
                }
            } catch (Throwable t) {
                cause = t;
            } finally {
                ReferenceCountUtil.release(msg);
                if (cause != null) {
                    setConnectFailure(cause);
                }
            }
        }
    }

Domain

Subdomains

Frequently Asked Questions

What does channelRead() do?
channelRead() is a function in the netty codebase, defined in handler-proxy/src/main/java/io/netty/handler/proxy/ProxyHandler.java.
Where is channelRead() defined?
channelRead() is defined in handler-proxy/src/main/java/io/netty/handler/proxy/ProxyHandler.java at line 246.
What does channelRead() call?
channelRead() calls 3 function(s): handleResponse, setConnectFailure, setConnectSuccess.

Analyze Your Own Codebase

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

Try Supermodel Free