adjustMaxBytesPerGatheringWrite() — netty Function Reference
Architecture documentation for the adjustMaxBytesPerGatheringWrite() function in AbstractKQueueStreamChannel.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD b80a7867_955d_4885_8e07_5d2861489576["adjustMaxBytesPerGatheringWrite()"] d154050d_32bb_fde7_fa64_5c82411c48d6["AbstractKQueueStreamChannel"] b80a7867_955d_4885_8e07_5d2861489576 -->|defined in| d154050d_32bb_fde7_fa64_5c82411c48d6 9c9d9b4b_f693_63b7_ac81_c2fc0c01e420["writeBytesMultiple()"] 9c9d9b4b_f693_63b7_ac81_c2fc0c01e420 -->|calls| b80a7867_955d_4885_8e07_5d2861489576 style b80a7867_955d_4885_8e07_5d2861489576 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
transport-classes-kqueue/src/main/java/io/netty/channel/kqueue/AbstractKQueueStreamChannel.java lines 120–131
private void adjustMaxBytesPerGatheringWrite(long attempted, long written, long oldMaxBytesPerGatheringWrite) {
// By default we track the SO_SNDBUF when ever it is explicitly set. However some OSes may dynamically change
// SO_SNDBUF (and other characteristics that determine how much data can be written at once) so we should try
// make a best effort to adjust as OS behavior changes.
if (attempted == written) {
if (attempted << 1 > oldMaxBytesPerGatheringWrite) {
config().setMaxBytesPerGatheringWrite(attempted << 1);
}
} else if (attempted > MAX_BYTES_PER_GATHERING_WRITE_ATTEMPTED_LOW_THRESHOLD && written < attempted >>> 1) {
config().setMaxBytesPerGatheringWrite(attempted >>> 1);
}
}
Domain
Subdomains
Defined In
Called By
Source
Frequently Asked Questions
What does adjustMaxBytesPerGatheringWrite() do?
adjustMaxBytesPerGatheringWrite() is a function in the netty codebase, defined in transport-classes-kqueue/src/main/java/io/netty/channel/kqueue/AbstractKQueueStreamChannel.java.
Where is adjustMaxBytesPerGatheringWrite() defined?
adjustMaxBytesPerGatheringWrite() is defined in transport-classes-kqueue/src/main/java/io/netty/channel/kqueue/AbstractKQueueStreamChannel.java at line 120.
What calls adjustMaxBytesPerGatheringWrite()?
adjustMaxBytesPerGatheringWrite() is called by 1 function(s): writeBytesMultiple.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free