doBeginRead() — netty Function Reference
Architecture documentation for the doBeginRead() function in LocalChannel.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD ca2fb8a0_ef70_093b_b9ef_d1b067cab979["doBeginRead()"] 81a44f54_ab3c_5f8b_4522_05c91e5f8eb8["LocalChannel"] ca2fb8a0_ef70_093b_b9ef_d1b067cab979 -->|defined in| 81a44f54_ab3c_5f8b_4522_05c91e5f8eb8 8dea8598_1c1b_dfae_1755_385916268d62["readInbound()"] ca2fb8a0_ef70_093b_b9ef_d1b067cab979 -->|calls| 8dea8598_1c1b_dfae_1755_385916268d62 19db0fc8_1524_a49b_2c8e_8b165b94bc06["close()"] ca2fb8a0_ef70_093b_b9ef_d1b067cab979 -->|calls| 19db0fc8_1524_a49b_2c8e_8b165b94bc06 style ca2fb8a0_ef70_093b_b9ef_d1b067cab979 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
transport/src/main/java/io/netty/channel/local/LocalChannel.java lines 337–368
@Override
protected void doBeginRead() throws Exception {
if (readInProgress) {
return;
}
Queue<Object> inboundBuffer = this.inboundBuffer;
if (inboundBuffer.isEmpty()) {
readInProgress = true;
return;
}
final InternalThreadLocalMap threadLocals = InternalThreadLocalMap.get();
final int stackDepth = threadLocals.localChannelReaderStackDepth();
if (stackDepth < MAX_READER_STACK_DEPTH) {
threadLocals.setLocalChannelReaderStackDepth(stackDepth + 1);
try {
readInbound();
} finally {
threadLocals.setLocalChannelReaderStackDepth(stackDepth);
}
} else {
try {
eventLoop().execute(readTask);
} catch (Throwable cause) {
logger.warn("Closing Local channels {}-{} because exception occurred!", this, peer, cause);
close();
peer.close();
PlatformDependent.throwException(cause);
}
}
}
Domain
Subdomains
Calls
Source
Frequently Asked Questions
What does doBeginRead() do?
doBeginRead() is a function in the netty codebase, defined in transport/src/main/java/io/netty/channel/local/LocalChannel.java.
Where is doBeginRead() defined?
doBeginRead() is defined in transport/src/main/java/io/netty/channel/local/LocalChannel.java at line 337.
What does doBeginRead() call?
doBeginRead() calls 2 function(s): close, readInbound.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free