private void UpdateBytesUsed() { long newBytesUsed = pending.RamBytesUsed() + pendingCounts.RamBytesUsed(); iwBytesUsed.AddAndGet(newBytesUsed - bytesUsed); bytesUsed = newBytesUsed; }
private void UpdateBytesUsed() { long newBytesUsed = lengths.RamBytesUsed() + bytes.RamBytesUsed() + DocsWithFieldBytesUsed(); iwBytesUsed.AddAndGet(newBytesUsed - bytesUsed); bytesUsed = newBytesUsed; }
public NumericDocValuesWriter(FieldInfo fieldInfo, Counter iwBytesUsed, bool trackDocsWithField) { pending = new AppendingDeltaPackedInt64Buffer(PackedInt32s.COMPACT); docsWithField = trackDocsWithField ? new FixedBitSet(64) : null; bytesUsed = pending.RamBytesUsed() + DocsWithFieldBytesUsed(); this.fieldInfo = fieldInfo; this.iwBytesUsed = iwBytesUsed; iwBytesUsed.AddAndGet(bytesUsed); }
public SortedDocValuesWriter(FieldInfo fieldInfo, Counter iwBytesUsed) { this.fieldInfo = fieldInfo; this.iwBytesUsed = iwBytesUsed; hash = new BytesRefHash(new ByteBlockPool(new ByteBlockPool.DirectTrackingAllocator(iwBytesUsed)), BytesRefHash.DEFAULT_CAPACITY, new BytesRefHash.DirectBytesStartArray(BytesRefHash.DEFAULT_CAPACITY, iwBytesUsed)); pending = new AppendingDeltaPackedInt64Buffer(PackedInt32s.COMPACT); bytesUsed = pending.RamBytesUsed(); iwBytesUsed.AddAndGet(bytesUsed); }