public abstract class TimePartitioning extends Object implements Serializable
Modifier and Type | Class and Description |
---|---|
static class |
TimePartitioning.Builder |
static class |
TimePartitioning.Type
The type of time partitioning.
|
Modifier and Type | Method and Description |
---|---|
abstract Long |
getExpirationMs()
Returns the number of milliseconds for which to keep the storage for a partition.
|
abstract String |
getField()
If not set, the table is partitioned by pseudo column '_PARTITIONTIME'; if set, the table is
partitioned by this field.
|
abstract Boolean |
getRequirePartitionFilter()
If set to true, queries over this table require a partition filter (that can be used for
partition elimination) to be specified.
|
abstract TimePartitioning.Type |
getType()
Returns the time partitioning type.
|
static TimePartitioning.Builder |
newBuilder(TimePartitioning.Type type)
Returns a
TimePartitioning object given the time partitioning type. |
static TimePartitioning |
of(TimePartitioning.Type type)
Returns a
TimePartitioning object given the time partitioning type. |
static TimePartitioning |
of(TimePartitioning.Type type,
long expirationMs)
Returns a
TimePartitioning object given the time partitioning type and the partition's
expiration in milliseconds. |
abstract TimePartitioning.Builder |
toBuilder() |
public abstract TimePartitioning.Type getType()
TimePartitioning.Type.DAY
,
which will generate one partition per day based on data loading time.@Nullable public abstract Long getExpirationMs()
@BetaApi @Nullable public abstract String getField()
@BetaApi @Nullable public abstract Boolean getRequirePartitionFilter()
public abstract TimePartitioning.Builder toBuilder()
public static TimePartitioning.Builder newBuilder(TimePartitioning.Type type)
TimePartitioning
object given the time partitioning type. Currently, the only
type supported is TimePartitioning.Type.DAY
, which will generate one partition per day based on data
loading time.public static TimePartitioning of(TimePartitioning.Type type)
TimePartitioning
object given the time partitioning type. Currently, the only
type supported is TimePartitioning.Type.DAY
, which will generate one partition per day based on data
loading time. The partitions will not expire.public static TimePartitioning of(TimePartitioning.Type type, long expirationMs)
TimePartitioning
object given the time partitioning type and the partition's
expiration in milliseconds.type
- the time partitioning type. Currently, the only type supported is TimePartitioning.Type.DAY
,
which will generate one partition per day based on data loading time.expirationMs
- the number of milliseconds for which to keep the storage for a partitionCopyright © 2019 Google LLC. All rights reserved.