Class ArrayByteBufferPool

java.lang.Object
org.eclipse.jetty.io.AbstractByteBufferPool
org.eclipse.jetty.io.ArrayByteBufferPool
All Implemented Interfaces:
ByteBufferPool

@ManagedObject public class ArrayByteBufferPool extends AbstractByteBufferPool

A ByteBuffer pool where ByteBuffers are held in queues that are held in array elements.

Given a capacity factor of 1024, the first array element holds a queue of ByteBuffers each of capacity 1024, the second array element holds a queue of ByteBuffers each of capacity 2048, and so on.

  • Field Details

  • Constructor Details

    • ArrayByteBufferPool

      public ArrayByteBufferPool()
      Creates a new ArrayByteBufferPool with a default configuration.
    • ArrayByteBufferPool

      public ArrayByteBufferPool(int minCapacity, int factor, int maxCapacity)
      Creates a new ArrayByteBufferPool with the given configuration.
      Parameters:
      minCapacity - the minimum ByteBuffer capacity
      factor - the capacity factor
      maxCapacity - the maximum ByteBuffer capacity
    • ArrayByteBufferPool

      public ArrayByteBufferPool(int minCapacity, int factor, int maxCapacity, int maxQueueLength)
      Creates a new ArrayByteBufferPool with the given configuration.
      Parameters:
      minCapacity - the minimum ByteBuffer capacity
      factor - the capacity factor
      maxCapacity - the maximum ByteBuffer capacity
      maxQueueLength - the maximum ByteBuffer queue length
    • ArrayByteBufferPool

      public ArrayByteBufferPool(int minCapacity, int factor, int maxCapacity, int maxQueueLength, long maxHeapMemory, long maxDirectMemory)
      Creates a new ArrayByteBufferPool with the given configuration.
      Parameters:
      minCapacity - the minimum ByteBuffer capacity
      factor - the capacity factor
      maxCapacity - the maximum ByteBuffer capacity
      maxQueueLength - the maximum ByteBuffer queue length
      maxHeapMemory - the max heap memory in bytes
      maxDirectMemory - the max direct memory in bytes
  • Method Details