/** * Gets the number of memory segments used by this partition, which includes build side * memory buffers and overflow memory segments. * * @return The number of occupied memory segments. */ public int getNumOccupiedMemorySegments() { // either the number of memory segments, or one for spilling final int numPartitionBuffers = this.partitionBuffers != null ? this.partitionBuffers.length : this.buildSideWriteBuffer.getNumOccupiedMemorySegments(); return numPartitionBuffers + numOverflowSegments; }
/** * Gets the number of memory segments used by this partition, which includes build side * memory buffers and overflow memory segments. * * @return The number of occupied memory segments. */ public int getNumOccupiedMemorySegments() { // either the number of memory segments, or one for spilling final int numPartitionBuffers = this.partitionBuffers != null ? this.partitionBuffers.length : this.buildSideWriteBuffer.getNumOccupiedMemorySegments(); return numPartitionBuffers + numOverflowSegments; }
/** * Gets the number of memory segments used by this partition, which includes build side * memory buffers and overflow memory segments. * * @return The number of occupied memory segments. */ public int getNumOccupiedMemorySegments() { // either the number of memory segments, or one for spilling final int numPartitionBuffers = this.partitionBuffers != null ? this.partitionBuffers.length : this.buildSideWriteBuffer.getNumOccupiedMemorySegments(); return numPartitionBuffers + numOverflowSegments; }
/** * Gets the number of memory segments used by this partition, which includes build side * memory buffers and overflow memory segments. * * @return The number of occupied memory segments. */ public int getNumOccupiedMemorySegments() { // either the number of memory segments, or one for spilling final int numPartitionBuffers = this.partitionBuffers != null ? this.partitionBuffers.length : this.buildSideWriteBuffer.getNumOccupiedMemorySegments(); return numPartitionBuffers + numOverflowSegments; }