Example usage for io.netty.buffer PoolChunkMetric usage

List of usage examples for io.netty.buffer PoolChunkMetric usage

Introduction

In this page you can find the example usage for io.netty.buffer PoolChunkMetric usage.

Prototype

int usage();

Source Link

Document

Return the percentage of the current usage of the chunk.

Usage

From source file:com.yahoo.pulsar.broker.stats.AllocatorStatsGenerator.java

License:Apache License

private static PoolChunkStats newPoolChunkStats(PoolChunkMetric m) {
    PoolChunkStats stats = new PoolChunkStats();
    stats.usage = m.usage();
    stats.chunkSize = m.chunkSize();/*from   w  ww  .  ja va 2s. c o m*/
    stats.freeBytes = m.freeBytes();
    return stats;
}