Class TableCreateOptions
- All Implemented Interfaces:
Serializable
CreateDisposition.CREATE_IF_NEEDED: its
column families and, per family, an optional garbage-collection rule.
Unlike the Pub/Sub sink's topic settings, this object is required beside
CREATE_IF_NEEDED rather than additive: a topic can meaningfully be created with defaults, but a
Bigtable table's schema is its column families, which the sink cannot guess — a table created
without them rejects every mutation and is a table someone has to fix later. Combining options
with CreateDisposition.CREATE_NEVER is rejected at build(), and so is
CREATE_IF_NEEDED without options.
Creation only, per family. A table that already exists is written to as it is: the
families declared here that it lacks are added — with their rules — but an existing family's
garbage-collection rule is neither compared nor updated. A family declared without a rule keeps
Bigtable's default of collecting nothing; see GcRule for why that choice matters for an
at-least-once sink.
Validation stops at what would otherwise fail obscurely (a blank name, an empty family set); Bigtable's own name grammar and limits are left to the service, whose rejection names the field and the limit. Instances are immutable and serializable.
- See Also:
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionstatic TableCreateOptions.Builderbuilder()Creates a newTableCreateOptions.Builder.booleanReturns the column families to create, in declaration order, each mapped to its garbage-collection rule or tonullfor none.inthashCode()toString()
-
Method Details
-
builder
Creates a newTableCreateOptions.Builder.- Returns:
- a new builder
-
getColumnFamilies
Returns the column families to create, in declaration order, each mapped to its garbage-collection rule or tonullfor none. -
equals
-
hashCode
public int hashCode() -
toString
-