class

HT2::AdaptiveBufferManager

Inherits Reference < Object

Manages adaptive buffer sizing based on connection patterns

Constants

ADAPTATION_FACTOR = 1.5
BUFFER_SIZES = [4096, 8192, 16384, 32768, 65536, 131072]

Common buffer size buckets

DEFAULT_CHUNK_SIZE = 16384
DEFAULT_READ_BUFFER_SIZE = 16384

Default sizes

DEFAULT_WRITE_BUFFER_SIZE = 65536
MIN_SAMPLES = 10

Adaptation parameters

Constructors

Instance methods

clear

Clear all recorded data

Source
record_frame_size(size : Int32) : Nil

Record an observed frame size

Source
record_write_size(size : Int32) : Nil

Record a write operation size

Source
should_adapt?

Check if adaptation is needed

Source
stats

Get current statistics

Source