Package org.apache.druid.segment
Class AutoTypeColumnSchema
java.lang.Object
org.apache.druid.data.input.impl.DimensionSchema
org.apache.druid.segment.AutoTypeColumnSchema
Common
DimensionSchema for ingestion of 'standard' Druid built-in ColumnType datatypes.
Automatically determines the most appropriate type for the given input data, able to produce columns of type:
ColumnType.STRING
ColumnType.STRING_ARRAY
ColumnType.LONG
ColumnType.LONG_ARRAY
ColumnType.DOUBLE
ColumnType.DOUBLE_ARRAY
ColumnType.NESTED_DATA
and includes bitmap value set indexes. Input of mixed type will be stored as ColumnType.NESTED_DATA.- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.druid.data.input.impl.DimensionSchema
DimensionSchema.MultiValueHandling -
Field Summary
FieldsFields inherited from class org.apache.druid.data.input.impl.DimensionSchema
DOUBLE_TYPE_NAME, FLOAT_TYPE_NAME, LONG_TYPE_NAME, SPATIAL_TYPE_NAME, STRING_TYPE_NAME -
Constructor Summary
ConstructorsConstructorDescriptionAutoTypeColumnSchema(String name, ColumnType castToType, NestedCommonFormatColumnFormatSpec columnFormatSpec) -
Method Summary
Modifier and TypeMethodDescriptionbooleangetEffectiveSchema(IndexSpec indexSpec) Computes the 'effective'DimensionSchema, allowing columns which provide mechanisms for customizing storage format to fill in values from the segment levelIndexSpecdefaults.inthashCode()static AutoTypeColumnSchematoString()Methods inherited from class org.apache.druid.data.input.impl.DimensionSchema
getDefaultSchemaForBuiltInType, getMultiValueHandling, getName, hasBitmapIndex
-
Field Details
-
TYPE
- See Also:
-
-
Constructor Details
-
AutoTypeColumnSchema
public AutoTypeColumnSchema(String name, @Nullable ColumnType castToType, @Nullable NestedCommonFormatColumnFormatSpec columnFormatSpec)
-
-
Method Details
-
of
-
getTypeName
- Specified by:
getTypeNamein classDimensionSchema
-
getColumnType
- Specified by:
getColumnTypein classDimensionSchema
-
getCastToType
-
getColumnFormatSpec
-
getDimensionHandler
- Overrides:
getDimensionHandlerin classDimensionSchema
-
getEffectiveSchema
Description copied from class:DimensionSchemaComputes the 'effective'DimensionSchema, allowing columns which provide mechanisms for customizing storage format to fill in values from the segment levelIndexSpecdefaults. This is useful for comparising the operator explicitly defined schema with the 'effective' schema that was written to the segments for things like comparing compaction state.- Overrides:
getEffectiveSchemain classDimensionSchema
-
equals
- Overrides:
equalsin classDimensionSchema
-
hashCode
public int hashCode()- Overrides:
hashCodein classDimensionSchema
-
toString
- Overrides:
toStringin classDimensionSchema
-