doReadMessages() — netty Function Reference
Architecture documentation for the doReadMessages() function in NioUdtMessageConnectorChannel.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD 15c0a337_3992_c373_c611_1ed18081aed4["doReadMessages()"] 06bc0141_1480_880a_48f9_8a253c01da1f["NioUdtMessageConnectorChannel"] 15c0a337_3992_c373_c611_1ed18081aed4 -->|defined in| 06bc0141_1480_880a_48f9_8a253c01da1f style 15c0a337_3992_c373_c611_1ed18081aed4 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
transport-udt/src/main/java/io/netty/channel/udt/nio/NioUdtMessageConnectorChannel.java lines 146–172
@Override
protected int doReadMessages(List<Object> buf) throws Exception {
final int maximumMessageSize = config.getReceiveBufferSize();
final ByteBuf byteBuf = config.getAllocator().directBuffer(
maximumMessageSize);
final int receivedMessageSize = byteBuf.writeBytes(javaChannel(),
maximumMessageSize);
if (receivedMessageSize <= 0) {
byteBuf.release();
return 0;
}
if (receivedMessageSize >= maximumMessageSize) {
javaChannel().close();
throw new ChannelException(
"Invalid config : increase receive buffer size to avoid message truncation");
}
// delivers a message
buf.add(new UdtMessage(byteBuf));
return 1;
}
Domain
Subdomains
Source
Frequently Asked Questions
What does doReadMessages() do?
doReadMessages() is a function in the netty codebase, defined in transport-udt/src/main/java/io/netty/channel/udt/nio/NioUdtMessageConnectorChannel.java.
Where is doReadMessages() defined?
doReadMessages() is defined in transport-udt/src/main/java/io/netty/channel/udt/nio/NioUdtMessageConnectorChannel.java at line 146.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free