Interface PartitionsSpec
-
- All Known Subinterfaces:
DimensionBasedPartitionsSpec
- All Known Implementing Classes:
DimensionRangePartitionsSpec,DynamicPartitionsSpec,HashedPartitionsSpec,SingleDimensionPartitionsSpec
public interface PartitionsSpecPartitionsSpec describes the secondary partitioning method for data ingestion.
-
-
Field Summary
Fields Modifier and Type Field Description static intDEFAULT_MAX_ROWS_PER_SEGMENTstatic intHISTORICAL_NULLstatic StringMAX_ROWS_PER_SEGMENT
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description StringgetForceGuaranteedRollupIncompatiblityReason()IntegergetMaxRowsPerSegment()Returns the max number of rows per segment.SecondaryPartitionTypegetType()static booleanisEffectivelyNull(Integer val)'-1' regarded as null for some historical reason.static booleanisEffectivelyNull(Long val)'-1' regarded as null for some historical reason.default booleanisForceGuaranteedRollupCompatible()default booleanisForceGuaranteedRollupCompatibleType()booleanneedsDeterminePartitions(boolean useForHadoopTask)Returns true if this partitionsSpec needs to determine the number of partitions to start data ingestion.static IntegerresolveHistoricalNullIfNeeded(Integer val)
-
-
-
Field Detail
-
DEFAULT_MAX_ROWS_PER_SEGMENT
static final int DEFAULT_MAX_ROWS_PER_SEGMENT
- See Also:
- Constant Field Values
-
MAX_ROWS_PER_SEGMENT
static final String MAX_ROWS_PER_SEGMENT
- See Also:
- Constant Field Values
-
HISTORICAL_NULL
static final int HISTORICAL_NULL
- See Also:
- Constant Field Values
-
-
Method Detail
-
getType
SecondaryPartitionType getType()
-
getMaxRowsPerSegment
@Nullable Integer getMaxRowsPerSegment()
Returns the max number of rows per segment. Implementations can have different default values which it could be even null. Callers should use the right value depending on the context if this returns null.
-
needsDeterminePartitions
boolean needsDeterminePartitions(boolean useForHadoopTask)
Returns true if this partitionsSpec needs to determine the number of partitions to start data ingestion. It should usually return true if perfect rollup is enforced but number of partitions is not specified.
-
isForceGuaranteedRollupCompatibleType
default boolean isForceGuaranteedRollupCompatibleType()
- Returns:
- True if this partitionSpec's type is compatible with forceGuaranteedRollup=true.
-
isForceGuaranteedRollupCompatible
default boolean isForceGuaranteedRollupCompatible()
- Returns:
- True if this partitionSpec's property values are compatible with forceGuaranteedRollup=true.
-
getForceGuaranteedRollupIncompatiblityReason
String getForceGuaranteedRollupIncompatiblityReason()
- Returns:
- Message describing why this partitionSpec is incompatible with forceGuaranteedRollup=true. Empty string if the partitionSpec is compatible.
-
isEffectivelyNull
static boolean isEffectivelyNull(@Nullable Integer val)
'-1' regarded as null for some historical reason.
-
isEffectivelyNull
static boolean isEffectivelyNull(@Nullable Long val)
'-1' regarded as null for some historical reason.
-
-