...
Package table
Overview ▹
Index ▹
Variables
var Table_TimestampGranularity_name = map[int32]string{
0: "MILLIS",
}
var Table_TimestampGranularity_value = map[string]int32{
"MILLIS": 0,
}
func RegisterBigtableTableServiceServer ¶
func RegisterBigtableTableServiceServer(s *grpc.Server, srv BigtableTableServiceServer)
type BigtableTableServiceClient ¶
type BigtableTableServiceClient interface {
// Creates a new table, to be served from a specified cluster.
// The table can be created with a full set of initial column families,
// specified in the request.
CreateTable(ctx context.Context, in *CreateTableRequest, opts ...grpc.CallOption) (*Table, error)
// Lists the names of all tables served from a specified cluster.
ListTables(ctx context.Context, in *ListTablesRequest, opts ...grpc.CallOption) (*ListTablesResponse, error)
// Gets the schema of the specified table, including its column families.
GetTable(ctx context.Context, in *GetTableRequest, opts ...grpc.CallOption) (*Table, error)
// Permanently deletes a specified table and all of its data.
DeleteTable(ctx context.Context, in *DeleteTableRequest, opts ...grpc.CallOption) (*google_protobuf2.Empty, error)
// Changes the name of a specified table.
// Cannot be used to move tables between clusters, zones, or projects.
RenameTable(ctx context.Context, in *RenameTableRequest, opts ...grpc.CallOption) (*google_protobuf2.Empty, error)
// Creates a new column family within a specified table.
CreateColumnFamily(ctx context.Context, in *CreateColumnFamilyRequest, opts ...grpc.CallOption) (*ColumnFamily, error)
// Changes the configuration of a specified column family.
UpdateColumnFamily(ctx context.Context, in *ColumnFamily, opts ...grpc.CallOption) (*ColumnFamily, error)
// Permanently deletes a specified column family and all of its data.
DeleteColumnFamily(ctx context.Context, in *DeleteColumnFamilyRequest, opts ...grpc.CallOption) (*google_protobuf2.Empty, error)
// Delete all rows in a table corresponding to a particular prefix
BulkDeleteRows(ctx context.Context, in *BulkDeleteRowsRequest, opts ...grpc.CallOption) (*google_protobuf2.Empty, error)
}
func NewBigtableTableServiceClient ¶
func NewBigtableTableServiceClient(cc *grpc.ClientConn) BigtableTableServiceClient
type BigtableTableServiceServer ¶
type BigtableTableServiceServer interface {
// Creates a new table, to be served from a specified cluster.
// The table can be created with a full set of initial column families,
// specified in the request.
CreateTable(context.Context, *CreateTableRequest) (*Table, error)
// Lists the names of all tables served from a specified cluster.
ListTables(context.Context, *ListTablesRequest) (*ListTablesResponse, error)
// Gets the schema of the specified table, including its column families.
GetTable(context.Context, *GetTableRequest) (*Table, error)
// Permanently deletes a specified table and all of its data.
DeleteTable(context.Context, *DeleteTableRequest) (*google_protobuf2.Empty, error)
// Changes the name of a specified table.
// Cannot be used to move tables between clusters, zones, or projects.
RenameTable(context.Context, *RenameTableRequest) (*google_protobuf2.Empty, error)
// Creates a new column family within a specified table.
CreateColumnFamily(context.Context, *CreateColumnFamilyRequest) (*ColumnFamily, error)
// Changes the configuration of a specified column family.
UpdateColumnFamily(context.Context, *ColumnFamily) (*ColumnFamily, error)
// Permanently deletes a specified column family and all of its data.
DeleteColumnFamily(context.Context, *DeleteColumnFamilyRequest) (*google_protobuf2.Empty, error)
// Delete all rows in a table corresponding to a particular prefix
BulkDeleteRows(context.Context, *BulkDeleteRowsRequest) (*google_protobuf2.Empty, error)
}
type BulkDeleteRowsRequest ¶
type BulkDeleteRowsRequest struct {
// The unique name of the table on which to perform the bulk delete
TableName string `protobuf:"bytes,1,opt,name=table_name,json=tableName" json:"table_name,omitempty"`
// Types that are valid to be assigned to Target:
// *BulkDeleteRowsRequest_RowKeyPrefix
// *BulkDeleteRowsRequest_DeleteAllDataFromTable
Target isBulkDeleteRowsRequest_Target `protobuf_oneof:"target"`
}
func (*BulkDeleteRowsRequest) Descriptor ¶
func (*BulkDeleteRowsRequest) Descriptor() ([]byte, []int)
func (*BulkDeleteRowsRequest) GetDeleteAllDataFromTable ¶
func (m *BulkDeleteRowsRequest) GetDeleteAllDataFromTable() bool
func (*BulkDeleteRowsRequest) GetRowKeyPrefix ¶
func (m *BulkDeleteRowsRequest) GetRowKeyPrefix() []byte
func (*BulkDeleteRowsRequest) GetTableName ¶
func (m *BulkDeleteRowsRequest) GetTableName() string
func (*BulkDeleteRowsRequest) GetTarget ¶
func (m *BulkDeleteRowsRequest) GetTarget() isBulkDeleteRowsRequest_Target
func (*BulkDeleteRowsRequest) ProtoMessage ¶
func (*BulkDeleteRowsRequest) ProtoMessage()
func (*BulkDeleteRowsRequest) Reset ¶
func (m *BulkDeleteRowsRequest) Reset()
func (*BulkDeleteRowsRequest) String ¶
func (m *BulkDeleteRowsRequest) String() string
func (*BulkDeleteRowsRequest) XXX_OneofFuncs ¶
func (*BulkDeleteRowsRequest) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{})
XXX_OneofFuncs is for the internal use of the proto package.
type BulkDeleteRowsRequest_DeleteAllDataFromTable ¶
type BulkDeleteRowsRequest_DeleteAllDataFromTable struct {
DeleteAllDataFromTable bool `protobuf:"varint,3,opt,name=delete_all_data_from_table,json=deleteAllDataFromTable,oneof"`
}
type BulkDeleteRowsRequest_RowKeyPrefix ¶
type BulkDeleteRowsRequest_RowKeyPrefix struct {
RowKeyPrefix []byte `protobuf:"bytes,2,opt,name=row_key_prefix,json=rowKeyPrefix,proto3,oneof"`
}
type ColumnFamily ¶
A set of columns within a table which share a common configuration.
type ColumnFamily struct {
// A unique identifier of the form <table_name>/columnFamilies/[-_.a-zA-Z0-9]+
// The last segment is the same as the "name" field in
// google.bigtable.v1.Family.
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
// Garbage collection expression specified by the following grammar:
// GC = EXPR
// | "" ;
// EXPR = EXPR, "||", EXPR (* lowest precedence *)
// | EXPR, "&&", EXPR
// | "(", EXPR, ")" (* highest precedence *)
// | PROP ;
// PROP = "version() >", NUM32
// | "age() >", NUM64, [ UNIT ] ;
// NUM32 = non-zero-digit { digit } ; (* # NUM32 <= 2^32 - 1 *)
// NUM64 = non-zero-digit { digit } ; (* # NUM64 <= 2^63 - 1 *)
// UNIT = "d" | "h" | "m" (* d=days, h=hours, m=minutes, else micros *)
// GC expressions can be up to 500 characters in length
//
// The different types of PROP are defined as follows:
// version() - cell index, counting from most recent and starting at 1
// age() - age of the cell (current time minus cell timestamp)
//
// Example: "version() > 3 || (age() > 3d && version() > 1)"
// drop cells beyond the most recent three, and drop cells older than three
// days unless they're the most recent cell in the row/column
//
// Garbage collection executes opportunistically in the background, and so
// it's possible for reads to return a cell even if it matches the active GC
// expression for its family.
GcExpression string `protobuf:"bytes,2,opt,name=gc_expression,json=gcExpression" json:"gc_expression,omitempty"`
// Garbage collection rule specified as a protobuf.
// Supersedes `gc_expression`.
// Must serialize to at most 500 bytes.
//
// NOTE: Garbage collection executes opportunistically in the background, and
// so it's possible for reads to return a cell even if it matches the active
// GC expression for its family.
GcRule *GcRule `protobuf:"bytes,3,opt,name=gc_rule,json=gcRule" json:"gc_rule,omitempty"`
}
func (*ColumnFamily) Descriptor ¶
func (*ColumnFamily) Descriptor() ([]byte, []int)
func (*ColumnFamily) GetGcExpression ¶
func (m *ColumnFamily) GetGcExpression() string
func (*ColumnFamily) GetGcRule ¶
func (m *ColumnFamily) GetGcRule() *GcRule
func (*ColumnFamily) GetName ¶
func (m *ColumnFamily) GetName() string
func (*ColumnFamily) ProtoMessage ¶
func (*ColumnFamily) ProtoMessage()
func (*ColumnFamily) Reset ¶
func (m *ColumnFamily) Reset()
func (*ColumnFamily) String ¶
func (m *ColumnFamily) String() string
type CreateColumnFamilyRequest ¶
type CreateColumnFamilyRequest struct {
// The unique name of the table in which to create the new column family.
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
// The name by which the new column family should be referred to within the
// table, e.g. "foobar" rather than "<table_name>/columnFamilies/foobar".
ColumnFamilyId string `protobuf:"bytes,2,opt,name=column_family_id,json=columnFamilyId" json:"column_family_id,omitempty"`
// The column family to create. The `name` field must be left blank.
ColumnFamily *ColumnFamily `protobuf:"bytes,3,opt,name=column_family,json=columnFamily" json:"column_family,omitempty"`
}
func (*CreateColumnFamilyRequest) Descriptor ¶
func (*CreateColumnFamilyRequest) Descriptor() ([]byte, []int)
func (*CreateColumnFamilyRequest) GetColumnFamily ¶
func (m *CreateColumnFamilyRequest) GetColumnFamily() *ColumnFamily
func (*CreateColumnFamilyRequest) GetColumnFamilyId ¶
func (m *CreateColumnFamilyRequest) GetColumnFamilyId() string
func (*CreateColumnFamilyRequest) GetName ¶
func (m *CreateColumnFamilyRequest) GetName() string
func (*CreateColumnFamilyRequest) ProtoMessage ¶
func (*CreateColumnFamilyRequest) ProtoMessage()
func (*CreateColumnFamilyRequest) Reset ¶
func (m *CreateColumnFamilyRequest) Reset()
func (*CreateColumnFamilyRequest) String ¶
func (m *CreateColumnFamilyRequest) String() string
type CreateTableRequest ¶
type CreateTableRequest struct {
// The unique name of the cluster in which to create the new table.
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
// The name by which the new table should be referred to within the cluster,
// e.g. "foobar" rather than "<cluster_name>/tables/foobar".
TableId string `protobuf:"bytes,2,opt,name=table_id,json=tableId" json:"table_id,omitempty"`
// The Table to create. The `name` field of the Table and all of its
// ColumnFamilies must be left blank, and will be populated in the response.
Table *Table `protobuf:"bytes,3,opt,name=table" json:"table,omitempty"`
// The optional list of row keys that will be used to initially split the
// table into several tablets (Tablets are similar to HBase regions).
// Given two split keys, "s1" and "s2", three tablets will be created,
// spanning the key ranges: [, s1), [s1, s2), [s2, ).
//
// Example:
// * Row keys := ["a", "apple", "custom", "customer_1", "customer_2",
// "other", "zz"]
// * initial_split_keys := ["apple", "customer_1", "customer_2", "other"]
// * Key assignment:
// - Tablet 1 [, apple) => {"a"}.
// - Tablet 2 [apple, customer_1) => {"apple", "custom"}.
// - Tablet 3 [customer_1, customer_2) => {"customer_1"}.
// - Tablet 4 [customer_2, other) => {"customer_2"}.
// - Tablet 5 [other, ) => {"other", "zz"}.
InitialSplitKeys []string `protobuf:"bytes,4,rep,name=initial_split_keys,json=initialSplitKeys" json:"initial_split_keys,omitempty"`
}
func (*CreateTableRequest) Descriptor ¶
func (*CreateTableRequest) Descriptor() ([]byte, []int)
func (*CreateTableRequest) GetInitialSplitKeys ¶
func (m *CreateTableRequest) GetInitialSplitKeys() []string
func (*CreateTableRequest) GetName ¶
func (m *CreateTableRequest) GetName() string
func (*CreateTableRequest) GetTable ¶
func (m *CreateTableRequest) GetTable() *Table
func (*CreateTableRequest) GetTableId ¶
func (m *CreateTableRequest) GetTableId() string
func (*CreateTableRequest) ProtoMessage ¶
func (*CreateTableRequest) ProtoMessage()
func (*CreateTableRequest) Reset ¶
func (m *CreateTableRequest) Reset()
func (*CreateTableRequest) String ¶
func (m *CreateTableRequest) String() string
type DeleteColumnFamilyRequest ¶
type DeleteColumnFamilyRequest struct {
// The unique name of the column family to be deleted.
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
}
func (*DeleteColumnFamilyRequest) Descriptor ¶
func (*DeleteColumnFamilyRequest) Descriptor() ([]byte, []int)
func (*DeleteColumnFamilyRequest) GetName ¶
func (m *DeleteColumnFamilyRequest) GetName() string
func (*DeleteColumnFamilyRequest) ProtoMessage ¶
func (*DeleteColumnFamilyRequest) ProtoMessage()
func (*DeleteColumnFamilyRequest) Reset ¶
func (m *DeleteColumnFamilyRequest) Reset()
func (*DeleteColumnFamilyRequest) String ¶
func (m *DeleteColumnFamilyRequest) String() string
type DeleteTableRequest ¶
type DeleteTableRequest struct {
// The unique name of the table to be deleted.
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
}
func (*DeleteTableRequest) Descriptor ¶
func (*DeleteTableRequest) Descriptor() ([]byte, []int)
func (*DeleteTableRequest) GetName ¶
func (m *DeleteTableRequest) GetName() string
func (*DeleteTableRequest) ProtoMessage ¶
func (*DeleteTableRequest) ProtoMessage()
func (*DeleteTableRequest) Reset ¶
func (m *DeleteTableRequest) Reset()
func (*DeleteTableRequest) String ¶
func (m *DeleteTableRequest) String() string
type GcRule ¶
Rule for determining which cells to delete during garbage collection.
type GcRule struct {
// Types that are valid to be assigned to Rule:
// *GcRule_MaxNumVersions
// *GcRule_MaxAge
// *GcRule_Intersection_
// *GcRule_Union_
Rule isGcRule_Rule `protobuf_oneof:"rule"`
}
func (*GcRule) Descriptor ¶
func (*GcRule) Descriptor() ([]byte, []int)
func (*GcRule) GetIntersection ¶
func (m *GcRule) GetIntersection() *GcRule_Intersection
func (*GcRule) GetMaxAge ¶
func (m *GcRule) GetMaxAge() *google_protobuf3.Duration
func (*GcRule) GetMaxNumVersions ¶
func (m *GcRule) GetMaxNumVersions() int32
func (*GcRule) GetRule ¶
func (m *GcRule) GetRule() isGcRule_Rule
func (*GcRule) GetUnion ¶
func (m *GcRule) GetUnion() *GcRule_Union
func (*GcRule) ProtoMessage ¶
func (*GcRule) ProtoMessage()
func (*GcRule) Reset ¶
func (m *GcRule) Reset()
func (*GcRule) String ¶
func (m *GcRule) String() string
func (*GcRule) XXX_OneofFuncs ¶
func (*GcRule) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{})
XXX_OneofFuncs is for the internal use of the proto package.
type GcRule_Intersection ¶
A GcRule which deletes cells matching all of the given rules.
type GcRule_Intersection struct {
// Only delete cells which would be deleted by every element of `rules`.
Rules []*GcRule `protobuf:"bytes,1,rep,name=rules" json:"rules,omitempty"`
}
func (*GcRule_Intersection) Descriptor ¶
func (*GcRule_Intersection) Descriptor() ([]byte, []int)
func (*GcRule_Intersection) GetRules ¶
func (m *GcRule_Intersection) GetRules() []*GcRule
func (*GcRule_Intersection) ProtoMessage ¶
func (*GcRule_Intersection) ProtoMessage()
func (*GcRule_Intersection) Reset ¶
func (m *GcRule_Intersection) Reset()
func (*GcRule_Intersection) String ¶
func (m *GcRule_Intersection) String() string
type GcRule_Intersection_ ¶
type GcRule_Intersection_ struct {
Intersection *GcRule_Intersection `protobuf:"bytes,3,opt,name=intersection,oneof"`
}
type GcRule_MaxAge ¶
type GcRule_MaxAge struct {
MaxAge *google_protobuf3.Duration `protobuf:"bytes,2,opt,name=max_age,json=maxAge,oneof"`
}
type GcRule_MaxNumVersions ¶
type GcRule_MaxNumVersions struct {
MaxNumVersions int32 `protobuf:"varint,1,opt,name=max_num_versions,json=maxNumVersions,oneof"`
}
type GcRule_Union ¶
A GcRule which deletes cells matching any of the given rules.
type GcRule_Union struct {
// Delete cells which would be deleted by any element of `rules`.
Rules []*GcRule `protobuf:"bytes,1,rep,name=rules" json:"rules,omitempty"`
}
func (*GcRule_Union) Descriptor ¶
func (*GcRule_Union) Descriptor() ([]byte, []int)
func (*GcRule_Union) GetRules ¶
func (m *GcRule_Union) GetRules() []*GcRule
func (*GcRule_Union) ProtoMessage ¶
func (*GcRule_Union) ProtoMessage()
func (*GcRule_Union) Reset ¶
func (m *GcRule_Union) Reset()
func (*GcRule_Union) String ¶
func (m *GcRule_Union) String() string
type GcRule_Union_ ¶
type GcRule_Union_ struct {
Union *GcRule_Union `protobuf:"bytes,4,opt,name=union,oneof"`
}
type GetTableRequest ¶
type GetTableRequest struct {
// The unique name of the requested table.
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
}
func (*GetTableRequest) Descriptor ¶
func (*GetTableRequest) Descriptor() ([]byte, []int)
func (*GetTableRequest) GetName ¶
func (m *GetTableRequest) GetName() string
func (*GetTableRequest) ProtoMessage ¶
func (*GetTableRequest) ProtoMessage()
func (*GetTableRequest) Reset ¶
func (m *GetTableRequest) Reset()
func (*GetTableRequest) String ¶
func (m *GetTableRequest) String() string
type ListTablesRequest ¶
type ListTablesRequest struct {
// The unique name of the cluster for which tables should be listed.
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
}
func (*ListTablesRequest) Descriptor ¶
func (*ListTablesRequest) Descriptor() ([]byte, []int)
func (*ListTablesRequest) GetName ¶
func (m *ListTablesRequest) GetName() string
func (*ListTablesRequest) ProtoMessage ¶
func (*ListTablesRequest) ProtoMessage()
func (*ListTablesRequest) Reset ¶
func (m *ListTablesRequest) Reset()
func (*ListTablesRequest) String ¶
func (m *ListTablesRequest) String() string
type ListTablesResponse ¶
type ListTablesResponse struct {
// The tables present in the requested cluster.
// At present, only the names of the tables are populated.
Tables []*Table `protobuf:"bytes,1,rep,name=tables" json:"tables,omitempty"`
}
func (*ListTablesResponse) Descriptor ¶
func (*ListTablesResponse) Descriptor() ([]byte, []int)
func (*ListTablesResponse) GetTables ¶
func (m *ListTablesResponse) GetTables() []*Table
func (*ListTablesResponse) ProtoMessage ¶
func (*ListTablesResponse) ProtoMessage()
func (*ListTablesResponse) Reset ¶
func (m *ListTablesResponse) Reset()
func (*ListTablesResponse) String ¶
func (m *ListTablesResponse) String() string
type RenameTableRequest ¶
type RenameTableRequest struct {
// The current unique name of the table.
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
// The new name by which the table should be referred to within its containing
// cluster, e.g. "foobar" rather than "<cluster_name>/tables/foobar".
NewId string `protobuf:"bytes,2,opt,name=new_id,json=newId" json:"new_id,omitempty"`
}
func (*RenameTableRequest) Descriptor ¶
func (*RenameTableRequest) Descriptor() ([]byte, []int)
func (*RenameTableRequest) GetName ¶
func (m *RenameTableRequest) GetName() string
func (*RenameTableRequest) GetNewId ¶
func (m *RenameTableRequest) GetNewId() string
func (*RenameTableRequest) ProtoMessage ¶
func (*RenameTableRequest) ProtoMessage()
func (*RenameTableRequest) Reset ¶
func (m *RenameTableRequest) Reset()
func (*RenameTableRequest) String ¶
func (m *RenameTableRequest) String() string
type Table ¶
A collection of user data indexed by row, column, and timestamp. Each table is served using the resources of its parent cluster.
type Table struct {
// A unique identifier of the form
// <cluster_name>/tables/[_a-zA-Z0-9][-_.a-zA-Z0-9]*
Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
// If this Table is in the process of being created, the Operation used to
// track its progress. As long as this operation is present, the Table will
// not accept any Table Admin or Read/Write requests.
CurrentOperation *google_longrunning.Operation `protobuf:"bytes,2,opt,name=current_operation,json=currentOperation" json:"current_operation,omitempty"`
// The column families configured for this table, mapped by column family id.
ColumnFamilies map[string]*ColumnFamily `protobuf:"bytes,3,rep,name=column_families,json=columnFamilies" json:"column_families,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
// The granularity (e.g. MILLIS, MICROS) at which timestamps are stored in
// this table. Timestamps not matching the granularity will be rejected.
// Cannot be changed once the table is created.
Granularity Table_TimestampGranularity `protobuf:"varint,4,opt,name=granularity,enum=google.bigtable.admin.table.v1.Table_TimestampGranularity" json:"granularity,omitempty"`
}
func (*Table) Descriptor ¶
func (*Table) Descriptor() ([]byte, []int)
func (*Table) GetColumnFamilies ¶
func (m *Table) GetColumnFamilies() map[string]*ColumnFamily
func (*Table) GetCurrentOperation ¶
func (m *Table) GetCurrentOperation() *google_longrunning.Operation
func (*Table) GetGranularity ¶
func (m *Table) GetGranularity() Table_TimestampGranularity
func (*Table) GetName ¶
func (m *Table) GetName() string
func (*Table) ProtoMessage ¶
func (*Table) ProtoMessage()
func (*Table) Reset ¶
func (m *Table) Reset()
func (*Table) String ¶
func (m *Table) String() string
type Table_TimestampGranularity ¶
type Table_TimestampGranularity int32
const (
Table_MILLIS Table_TimestampGranularity = 0
)
func (Table_TimestampGranularity) EnumDescriptor ¶
func (Table_TimestampGranularity) EnumDescriptor() ([]byte, []int)
func (Table_TimestampGranularity) String ¶
func (x Table_TimestampGranularity) String() string
ActiveGo 1.8