内存和内存管理器的抽象
Java · 5 notes
- ByteBufhistorical
ByteBuf uses reader and writer indexes to divide consumed, readable, and writable regions. These notes examine read and write API behavior through those indexes.
- ByteBufAllocatorhistorical
ByteBufAllocator allocates ByteBuf instances. These notes follow the abstract buffer method to examine choices such as heap and direct memory.
- Usagehistorical
Code examples record Netty memory-related usage and provide a practical starting point for reading allocator implementations.
- PooledByteBufAllocatorhistorical
PooledByteBufAllocator obtains a thread cache and its PoolArena, then allocates memory through the arena. These notes trace both stages.
- PoolThreadCachehistorical
PoolThreadCache creates caches for memory regions of different sizes. These notes examine initialization of tiny, small, and normal MemoryRegionCache instances.