Class ElasticSerializableRowRecordList


  • public class ElasticSerializableRowRecordList
    extends java.lang.Object
    An elastic list of records that implements memory control using LRU strategy.
    • Field Detail

      • MEMORY_CHECK_THRESHOLD

        protected static final int MEMORY_CHECK_THRESHOLD
        See Also:
        Constant Field Values
      • dataTypes

        protected org.apache.iotdb.tsfile.file.metadata.enums.TSDataType[] dataTypes
      • queryId

        protected long queryId
      • memoryLimitInMB

        protected float memoryLimitInMB
      • internalRowRecordListCapacity

        protected int internalRowRecordListCapacity
      • numCacheBlock

        protected int numCacheBlock
      • cache

        protected org.apache.iotdb.db.mpp.transformation.datastructure.row.ElasticSerializableRowRecordList.LRUCache cache
      • bitMaps

        protected java.util.List<org.apache.iotdb.tsfile.utils.BitMap> bitMaps
        Mark bitMaps of correct index when one row has at least one null field
      • size

        protected int size
      • evictionUpperBound

        protected int evictionUpperBound
      • disableMemoryControl

        protected boolean disableMemoryControl
      • indexListOfTextFields

        protected int[] indexListOfTextFields
      • byteArrayLengthForMemoryControl

        protected int byteArrayLengthForMemoryControl
      • totalByteArrayLengthLimit

        protected long totalByteArrayLengthLimit
      • totalByteArrayLength

        protected long totalByteArrayLength
    • Constructor Detail

      • ElasticSerializableRowRecordList

        public ElasticSerializableRowRecordList​(org.apache.iotdb.tsfile.file.metadata.enums.TSDataType[] dataTypes,
                                                long queryId,
                                                float memoryLimitInMB,
                                                int numCacheBlock)
                                         throws QueryProcessException
        Construct a ElasticSerializableRowRecordList.
        Parameters:
        dataTypes - Data types of columns.
        queryId - Query ID.
        memoryLimitInMB - Memory limit.
        numCacheBlock - Number of cache blocks.
        Throws:
        QueryProcessException
      • ElasticSerializableRowRecordList

        protected ElasticSerializableRowRecordList​(org.apache.iotdb.tsfile.file.metadata.enums.TSDataType[] dataTypes,
                                                   long queryId,
                                                   float memoryLimitInMB,
                                                   int internalRowRecordListCapacity,
                                                   int numCacheBlock)
    • Method Detail

      • size

        public int size()
      • getDataTypes

        public org.apache.iotdb.tsfile.file.metadata.enums.TSDataType[] getDataTypes()
      • getTime

        public long getTime​(int index)
                     throws java.io.IOException
        Throws:
        java.io.IOException
      • getRowRecord

        public java.lang.Object[] getRowRecord​(int index)
                                        throws java.io.IOException
        Throws:
        java.io.IOException
      • fieldsHasAnyNull

        public boolean fieldsHasAnyNull​(int index)
        true if any field except the timestamp in the current row is null
      • applyNewMemoryControlParameters

        protected void applyNewMemoryControlParameters​(int newByteArrayLengthForMemoryControl,
                                                       int newInternalRowRecordListCapacity)
                                                throws java.io.IOException,
                                                       QueryProcessException
        Throws:
        java.io.IOException
        QueryProcessException
      • setEvictionUpperBound

        public void setEvictionUpperBound​(int evictionUpperBound)
        Parameters:
        evictionUpperBound - the index of the first element that cannot be evicted. in other words, elements whose index are less than the evictionUpperBound can be evicted.