Interface StorageAdapter

    • Method Detail

      • getInterval

        org.joda.time.Interval getInterval()
      • getAvailableDimensions

        Indexed<String> getAvailableDimensions()
      • getRowSignature

        default RowSignature getRowSignature()
        Returns the row signature of the data available from this adapter. For mutable adapters, even though the signature may evolve over time, any particular object returned by this method is an immutable snapshot.
      • getDimensionCardinality

        int getDimensionCardinality​(String column)
        Returns the number of distinct values for a column, or DimensionDictionarySelector.CARDINALITY_UNKNOWN if unknown. If the column doesn't exist, returns 1, because a column that doesn't exist is treated as a column of default (or null) values.
      • getMinValue

        @Nullable
        Comparable getMinValue​(String column)
        Returns the minimum value of the provided column, if known through an index, dictionary, or cache. Returns null if not known. Does not scan the column to find the minimum value.
      • getMaxValue

        @Nullable
        Comparable getMaxValue​(String column)
        Returns the minimum value of the provided column, if known through an index, dictionary, or cache. Returns null if not known. Does not scan the column to find the maximum value.
      • getColumnCapabilities

        @Nullable
        ColumnCapabilities getColumnCapabilities​(String column)
        Returns capabilities of a particular column, if known. May be null if the column doesn't exist, or if the column does exist but the capabilities are unknown. The latter is possible with dynamically discovered columns. Note that StorageAdapters are representations of "real" segments, so they are not aware of any virtual columns that may be involved in a query. In general, query engines should instead use the method ColumnSelectorFactory.getColumnCapabilities(String), which returns capabilities for virtual columns as well.
        Specified by:
        getColumnCapabilities in interface ColumnInspector
        Parameters:
        column - column name
        Returns:
        capabilities, or null
      • getNumRows

        int getNumRows()
      • getMaxIngestedEventTime

        org.joda.time.DateTime getMaxIngestedEventTime()
      • hasBuiltInFilters

        default boolean hasBuiltInFilters()
        Returns true if this storage adapter can filter some rows out. The actual column cardinality can be lower than what getDimensionCardinality(java.lang.String) returns if this returns true. Dimension selectors for such storage adapter can return non-contiguous dictionary IDs because the dictionary IDs in filtered rows will not be returned. Note that the number of rows accessible via this storage adapter will not necessarily decrease because of the built-in filters. For inner joins, for example, the number of joined rows can be larger than the number of rows in the base adapter even though this method returns true.
      • isFromTombstone

        default boolean isFromTombstone()
        Returns:
        true if this index was created from a tombstone or false otherwise