Documentation ¶
Index ¶
- Variables
- func RegisterDatabaseAdminServer(s *grpc.Server, srv DatabaseAdminServer)
- type CreateDatabaseMetadata
- func (*CreateDatabaseMetadata) Descriptor() ([]byte, []int)
- func (m *CreateDatabaseMetadata) GetDatabase() string
- func (*CreateDatabaseMetadata) ProtoMessage()
- func (m *CreateDatabaseMetadata) Reset()
- func (m *CreateDatabaseMetadata) String() string
- func (m *CreateDatabaseMetadata) XXX_DiscardUnknown()
- func (m *CreateDatabaseMetadata) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (dst *CreateDatabaseMetadata) XXX_Merge(src proto.Message)
- func (m *CreateDatabaseMetadata) XXX_Size() int
- func (m *CreateDatabaseMetadata) XXX_Unmarshal(b []byte) error
- type CreateDatabaseRequest
- func (*CreateDatabaseRequest) Descriptor() ([]byte, []int)
- func (m *CreateDatabaseRequest) GetCreateStatement() string
- func (m *CreateDatabaseRequest) GetExtraStatements() []string
- func (m *CreateDatabaseRequest) GetParent() string
- func (*CreateDatabaseRequest) ProtoMessage()
- func (m *CreateDatabaseRequest) Reset()
- func (m *CreateDatabaseRequest) String() string
- func (m *CreateDatabaseRequest) XXX_DiscardUnknown()
- func (m *CreateDatabaseRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (dst *CreateDatabaseRequest) XXX_Merge(src proto.Message)
- func (m *CreateDatabaseRequest) XXX_Size() int
- func (m *CreateDatabaseRequest) XXX_Unmarshal(b []byte) error
- type Database
- func (*Database) Descriptor() ([]byte, []int)
- func (m *Database) GetName() string
- func (m *Database) GetState() Database_State
- func (*Database) ProtoMessage()
- func (m *Database) Reset()
- func (m *Database) String() string
- func (m *Database) XXX_DiscardUnknown()
- func (m *Database) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (dst *Database) XXX_Merge(src proto.Message)
- func (m *Database) XXX_Size() int
- func (m *Database) XXX_Unmarshal(b []byte) error
- type DatabaseAdminClient
- type DatabaseAdminServer
- type Database_State
- type DropDatabaseRequest
- func (*DropDatabaseRequest) Descriptor() ([]byte, []int)
- func (m *DropDatabaseRequest) GetDatabase() string
- func (*DropDatabaseRequest) ProtoMessage()
- func (m *DropDatabaseRequest) Reset()
- func (m *DropDatabaseRequest) String() string
- func (m *DropDatabaseRequest) XXX_DiscardUnknown()
- func (m *DropDatabaseRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (dst *DropDatabaseRequest) XXX_Merge(src proto.Message)
- func (m *DropDatabaseRequest) XXX_Size() int
- func (m *DropDatabaseRequest) XXX_Unmarshal(b []byte) error
- type GetDatabaseDdlRequest
- func (*GetDatabaseDdlRequest) Descriptor() ([]byte, []int)
- func (m *GetDatabaseDdlRequest) GetDatabase() string
- func (*GetDatabaseDdlRequest) ProtoMessage()
- func (m *GetDatabaseDdlRequest) Reset()
- func (m *GetDatabaseDdlRequest) String() string
- func (m *GetDatabaseDdlRequest) XXX_DiscardUnknown()
- func (m *GetDatabaseDdlRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (dst *GetDatabaseDdlRequest) XXX_Merge(src proto.Message)
- func (m *GetDatabaseDdlRequest) XXX_Size() int
- func (m *GetDatabaseDdlRequest) XXX_Unmarshal(b []byte) error
- type GetDatabaseDdlResponse
- func (*GetDatabaseDdlResponse) Descriptor() ([]byte, []int)
- func (m *GetDatabaseDdlResponse) GetStatements() []string
- func (*GetDatabaseDdlResponse) ProtoMessage()
- func (m *GetDatabaseDdlResponse) Reset()
- func (m *GetDatabaseDdlResponse) String() string
- func (m *GetDatabaseDdlResponse) XXX_DiscardUnknown()
- func (m *GetDatabaseDdlResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (dst *GetDatabaseDdlResponse) XXX_Merge(src proto.Message)
- func (m *GetDatabaseDdlResponse) XXX_Size() int
- func (m *GetDatabaseDdlResponse) XXX_Unmarshal(b []byte) error
- type GetDatabaseRequest
- func (*GetDatabaseRequest) Descriptor() ([]byte, []int)
- func (m *GetDatabaseRequest) GetName() string
- func (*GetDatabaseRequest) ProtoMessage()
- func (m *GetDatabaseRequest) Reset()
- func (m *GetDatabaseRequest) String() string
- func (m *GetDatabaseRequest) XXX_DiscardUnknown()
- func (m *GetDatabaseRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (dst *GetDatabaseRequest) XXX_Merge(src proto.Message)
- func (m *GetDatabaseRequest) XXX_Size() int
- func (m *GetDatabaseRequest) XXX_Unmarshal(b []byte) error
- type ListDatabasesRequest
- func (*ListDatabasesRequest) Descriptor() ([]byte, []int)
- func (m *ListDatabasesRequest) GetPageSize() int32
- func (m *ListDatabasesRequest) GetPageToken() string
- func (m *ListDatabasesRequest) GetParent() string
- func (*ListDatabasesRequest) ProtoMessage()
- func (m *ListDatabasesRequest) Reset()
- func (m *ListDatabasesRequest) String() string
- func (m *ListDatabasesRequest) XXX_DiscardUnknown()
- func (m *ListDatabasesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (dst *ListDatabasesRequest) XXX_Merge(src proto.Message)
- func (m *ListDatabasesRequest) XXX_Size() int
- func (m *ListDatabasesRequest) XXX_Unmarshal(b []byte) error
- type ListDatabasesResponse
- func (*ListDatabasesResponse) Descriptor() ([]byte, []int)
- func (m *ListDatabasesResponse) GetDatabases() []*Database
- func (m *ListDatabasesResponse) GetNextPageToken() string
- func (*ListDatabasesResponse) ProtoMessage()
- func (m *ListDatabasesResponse) Reset()
- func (m *ListDatabasesResponse) String() string
- func (m *ListDatabasesResponse) XXX_DiscardUnknown()
- func (m *ListDatabasesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (dst *ListDatabasesResponse) XXX_Merge(src proto.Message)
- func (m *ListDatabasesResponse) XXX_Size() int
- func (m *ListDatabasesResponse) XXX_Unmarshal(b []byte) error
- type UpdateDatabaseDdlMetadata
- func (*UpdateDatabaseDdlMetadata) Descriptor() ([]byte, []int)
- func (m *UpdateDatabaseDdlMetadata) GetCommitTimestamps() []*timestamp.Timestamp
- func (m *UpdateDatabaseDdlMetadata) GetDatabase() string
- func (m *UpdateDatabaseDdlMetadata) GetStatements() []string
- func (*UpdateDatabaseDdlMetadata) ProtoMessage()
- func (m *UpdateDatabaseDdlMetadata) Reset()
- func (m *UpdateDatabaseDdlMetadata) String() string
- func (m *UpdateDatabaseDdlMetadata) XXX_DiscardUnknown()
- func (m *UpdateDatabaseDdlMetadata) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (dst *UpdateDatabaseDdlMetadata) XXX_Merge(src proto.Message)
- func (m *UpdateDatabaseDdlMetadata) XXX_Size() int
- func (m *UpdateDatabaseDdlMetadata) XXX_Unmarshal(b []byte) error
- type UpdateDatabaseDdlRequest
- func (*UpdateDatabaseDdlRequest) Descriptor() ([]byte, []int)
- func (m *UpdateDatabaseDdlRequest) GetDatabase() string
- func (m *UpdateDatabaseDdlRequest) GetOperationId() string
- func (m *UpdateDatabaseDdlRequest) GetStatements() []string
- func (*UpdateDatabaseDdlRequest) ProtoMessage()
- func (m *UpdateDatabaseDdlRequest) Reset()
- func (m *UpdateDatabaseDdlRequest) String() string
- func (m *UpdateDatabaseDdlRequest) XXX_DiscardUnknown()
- func (m *UpdateDatabaseDdlRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (dst *UpdateDatabaseDdlRequest) XXX_Merge(src proto.Message)
- func (m *UpdateDatabaseDdlRequest) XXX_Size() int
- func (m *UpdateDatabaseDdlRequest) XXX_Unmarshal(b []byte) error
Constants ¶
This section is empty.
Variables ¶
var Database_State_name = map[int32]string{
0: "STATE_UNSPECIFIED",
1: "CREATING",
2: "READY",
}
var Database_State_value = map[string]int32{
"STATE_UNSPECIFIED": 0,
"CREATING": 1,
"READY": 2,
}
Functions ¶
func RegisterDatabaseAdminServer ¶
func RegisterDatabaseAdminServer(s *grpc.Server, srv DatabaseAdminServer)
Types ¶
type CreateDatabaseMetadata ¶
type CreateDatabaseMetadata struct { // The database being created. Database string `protobuf:"bytes,1,opt,name=database,proto3" json:"database,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
Metadata type for the operation returned by [CreateDatabase][google.spanner.admin.database.v1.DatabaseAdmin.CreateDatabase].
func (*CreateDatabaseMetadata) Descriptor ¶
func (*CreateDatabaseMetadata) Descriptor() ([]byte, []int)
func (*CreateDatabaseMetadata) GetDatabase ¶
func (m *CreateDatabaseMetadata) GetDatabase() string
func (*CreateDatabaseMetadata) ProtoMessage ¶
func (*CreateDatabaseMetadata) ProtoMessage()
func (*CreateDatabaseMetadata) Reset ¶
func (m *CreateDatabaseMetadata) Reset()
func (*CreateDatabaseMetadata) String ¶
func (m *CreateDatabaseMetadata) String() string
func (*CreateDatabaseMetadata) XXX_DiscardUnknown ¶
func (m *CreateDatabaseMetadata) XXX_DiscardUnknown()
func (*CreateDatabaseMetadata) XXX_Marshal ¶
func (m *CreateDatabaseMetadata) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*CreateDatabaseMetadata) XXX_Merge ¶
func (dst *CreateDatabaseMetadata) XXX_Merge(src proto.Message)
func (*CreateDatabaseMetadata) XXX_Size ¶
func (m *CreateDatabaseMetadata) XXX_Size() int
func (*CreateDatabaseMetadata) XXX_Unmarshal ¶
func (m *CreateDatabaseMetadata) XXX_Unmarshal(b []byte) error
type CreateDatabaseRequest ¶
type CreateDatabaseRequest struct { // Required. The name of the instance that will serve the new database. // Values are of the form `projects/<project>/instances/<instance>`. Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"` // Required. A `CREATE DATABASE` statement, which specifies the ID of the // new database. The database ID must conform to the regular expression // `[a-z][a-z0-9_\-]*[a-z0-9]` and be between 2 and 30 characters in length. // If the database ID is a reserved word or if it contains a hyphen, the // database ID must be enclosed in backticks (“ ` “). CreateStatement string `protobuf:"bytes,2,opt,name=create_statement,json=createStatement,proto3" json:"create_statement,omitempty"` // An optional list of DDL statements to run inside the newly created // database. Statements can create tables, indexes, etc. These // statements execute atomically with the creation of the database: // if there is an error in any statement, the database is not created. ExtraStatements []string `protobuf:"bytes,3,rep,name=extra_statements,json=extraStatements,proto3" json:"extra_statements,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
The request for [CreateDatabase][google.spanner.admin.database.v1.DatabaseAdmin.CreateDatabase].
func (*CreateDatabaseRequest) Descriptor ¶
func (*CreateDatabaseRequest) Descriptor() ([]byte, []int)
func (*CreateDatabaseRequest) GetCreateStatement ¶
func (m *CreateDatabaseRequest) GetCreateStatement() string
func (*CreateDatabaseRequest) GetExtraStatements ¶
func (m *CreateDatabaseRequest) GetExtraStatements() []string
func (*CreateDatabaseRequest) GetParent ¶
func (m *CreateDatabaseRequest) GetParent() string
func (*CreateDatabaseRequest) ProtoMessage ¶
func (*CreateDatabaseRequest) ProtoMessage()
func (*CreateDatabaseRequest) Reset ¶
func (m *CreateDatabaseRequest) Reset()
func (*CreateDatabaseRequest) String ¶
func (m *CreateDatabaseRequest) String() string
func (*CreateDatabaseRequest) XXX_DiscardUnknown ¶
func (m *CreateDatabaseRequest) XXX_DiscardUnknown()
func (*CreateDatabaseRequest) XXX_Marshal ¶
func (m *CreateDatabaseRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*CreateDatabaseRequest) XXX_Merge ¶
func (dst *CreateDatabaseRequest) XXX_Merge(src proto.Message)
func (*CreateDatabaseRequest) XXX_Size ¶
func (m *CreateDatabaseRequest) XXX_Size() int
func (*CreateDatabaseRequest) XXX_Unmarshal ¶
func (m *CreateDatabaseRequest) XXX_Unmarshal(b []byte) error
type Database ¶
type Database struct { // Required. The name of the database. Values are of the form // `projects/<project>/instances/<instance>/databases/<database>`, // where `<database>` is as specified in the `CREATE DATABASE` // statement. This name can be passed to other API methods to // identify the database. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` // Output only. The current database state. State Database_State `protobuf:"varint,2,opt,name=state,proto3,enum=google.spanner.admin.database.v1.Database_State" json:"state,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
A Cloud Spanner database.
func (*Database) Descriptor ¶
func (*Database) GetState ¶
func (m *Database) GetState() Database_State
func (*Database) ProtoMessage ¶
func (*Database) ProtoMessage()
func (*Database) XXX_DiscardUnknown ¶
func (m *Database) XXX_DiscardUnknown()
func (*Database) XXX_Marshal ¶
func (*Database) XXX_Unmarshal ¶
type DatabaseAdminClient ¶
type DatabaseAdminClient interface { // Lists Cloud Spanner databases. ListDatabases(ctx context.Context, in *ListDatabasesRequest, opts ...grpc.CallOption) (*ListDatabasesResponse, error) // Creates a new Cloud Spanner database and starts to prepare it for serving. // The returned [long-running operation][google.longrunning.Operation] will // have a name of the format `<database_name>/operations/<operation_id>` and // can be used to track preparation of the database. The // [metadata][google.longrunning.Operation.metadata] field type is // [CreateDatabaseMetadata][google.spanner.admin.database.v1.CreateDatabaseMetadata]. The // [response][google.longrunning.Operation.response] field type is // [Database][google.spanner.admin.database.v1.Database], if successful. CreateDatabase(ctx context.Context, in *CreateDatabaseRequest, opts ...grpc.CallOption) (*longrunning.Operation, error) // Gets the state of a Cloud Spanner database. GetDatabase(ctx context.Context, in *GetDatabaseRequest, opts ...grpc.CallOption) (*Database, error) // Updates the schema of a Cloud Spanner database by // creating/altering/dropping tables, columns, indexes, etc. The returned // [long-running operation][google.longrunning.Operation] will have a name of // the format `<database_name>/operations/<operation_id>` and can be used to // track execution of the schema change(s). The // [metadata][google.longrunning.Operation.metadata] field type is // [UpdateDatabaseDdlMetadata][google.spanner.admin.database.v1.UpdateDatabaseDdlMetadata]. The operation has no response. UpdateDatabaseDdl(ctx context.Context, in *UpdateDatabaseDdlRequest, opts ...grpc.CallOption) (*longrunning.Operation, error) // Drops (aka deletes) a Cloud Spanner database. DropDatabase(ctx context.Context, in *DropDatabaseRequest, opts ...grpc.CallOption) (*empty.Empty, error) // Returns the schema of a Cloud Spanner database as a list of formatted // DDL statements. This method does not show pending schema updates, those may // be queried using the [Operations][google.longrunning.Operations] API. GetDatabaseDdl(ctx context.Context, in *GetDatabaseDdlRequest, opts ...grpc.CallOption) (*GetDatabaseDdlResponse, error) // Sets the access control policy on a database resource. Replaces any // existing policy. // // Authorization requires `spanner.databases.setIamPolicy` permission on // [resource][google.iam.v1.SetIamPolicyRequest.resource]. SetIamPolicy(ctx context.Context, in *v1.SetIamPolicyRequest, opts ...grpc.CallOption) (*v1.Policy, error) // Gets the access control policy for a database resource. Returns an empty // policy if a database exists but does not have a policy set. // // Authorization requires `spanner.databases.getIamPolicy` permission on // [resource][google.iam.v1.GetIamPolicyRequest.resource]. GetIamPolicy(ctx context.Context, in *v1.GetIamPolicyRequest, opts ...grpc.CallOption) (*v1.Policy, error) // Returns permissions that the caller has on the specified database resource. // // Attempting this RPC on a non-existent Cloud Spanner database will result in // a NOT_FOUND error if the user has `spanner.databases.list` permission on // the containing Cloud Spanner instance. Otherwise returns an empty set of // permissions. TestIamPermissions(ctx context.Context, in *v1.TestIamPermissionsRequest, opts ...grpc.CallOption) (*v1.TestIamPermissionsResponse, error) }
DatabaseAdminClient is the client API for DatabaseAdmin service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
func NewDatabaseAdminClient ¶
func NewDatabaseAdminClient(cc *grpc.ClientConn) DatabaseAdminClient
type DatabaseAdminServer ¶
type DatabaseAdminServer interface { // Lists Cloud Spanner databases. ListDatabases(context.Context, *ListDatabasesRequest) (*ListDatabasesResponse, error) // Creates a new Cloud Spanner database and starts to prepare it for serving. // The returned [long-running operation][google.longrunning.Operation] will // have a name of the format `<database_name>/operations/<operation_id>` and // can be used to track preparation of the database. The // [metadata][google.longrunning.Operation.metadata] field type is // [CreateDatabaseMetadata][google.spanner.admin.database.v1.CreateDatabaseMetadata]. The // [response][google.longrunning.Operation.response] field type is // [Database][google.spanner.admin.database.v1.Database], if successful. CreateDatabase(context.Context, *CreateDatabaseRequest) (*longrunning.Operation, error) // Gets the state of a Cloud Spanner database. GetDatabase(context.Context, *GetDatabaseRequest) (*Database, error) // Updates the schema of a Cloud Spanner database by // creating/altering/dropping tables, columns, indexes, etc. The returned // [long-running operation][google.longrunning.Operation] will have a name of // the format `<database_name>/operations/<operation_id>` and can be used to // track execution of the schema change(s). The // [metadata][google.longrunning.Operation.metadata] field type is // [UpdateDatabaseDdlMetadata][google.spanner.admin.database.v1.UpdateDatabaseDdlMetadata]. The operation has no response. UpdateDatabaseDdl(context.Context, *UpdateDatabaseDdlRequest) (*longrunning.Operation, error) // Drops (aka deletes) a Cloud Spanner database. DropDatabase(context.Context, *DropDatabaseRequest) (*empty.Empty, error) // Returns the schema of a Cloud Spanner database as a list of formatted // DDL statements. This method does not show pending schema updates, those may // be queried using the [Operations][google.longrunning.Operations] API. GetDatabaseDdl(context.Context, *GetDatabaseDdlRequest) (*GetDatabaseDdlResponse, error) // Sets the access control policy on a database resource. Replaces any // existing policy. // // Authorization requires `spanner.databases.setIamPolicy` permission on // [resource][google.iam.v1.SetIamPolicyRequest.resource]. SetIamPolicy(context.Context, *v1.SetIamPolicyRequest) (*v1.Policy, error) // Gets the access control policy for a database resource. Returns an empty // policy if a database exists but does not have a policy set. // // Authorization requires `spanner.databases.getIamPolicy` permission on // [resource][google.iam.v1.GetIamPolicyRequest.resource]. GetIamPolicy(context.Context, *v1.GetIamPolicyRequest) (*v1.Policy, error) // Returns permissions that the caller has on the specified database resource. // // Attempting this RPC on a non-existent Cloud Spanner database will result in // a NOT_FOUND error if the user has `spanner.databases.list` permission on // the containing Cloud Spanner instance. Otherwise returns an empty set of // permissions. TestIamPermissions(context.Context, *v1.TestIamPermissionsRequest) (*v1.TestIamPermissionsResponse, error) }
DatabaseAdminServer is the server API for DatabaseAdmin service.
type Database_State ¶
type Database_State int32
Indicates the current state of the database.
const ( // Not specified. Database_STATE_UNSPECIFIED Database_State = 0 // The database is still being created. Operations on the database may fail // with `FAILED_PRECONDITION` in this state. Database_CREATING Database_State = 1 // The database is fully created and ready for use. Database_READY Database_State = 2 )
func (Database_State) EnumDescriptor ¶
func (Database_State) EnumDescriptor() ([]byte, []int)
func (Database_State) String ¶
func (x Database_State) String() string
type DropDatabaseRequest ¶
type DropDatabaseRequest struct { // Required. The database to be dropped. Database string `protobuf:"bytes,1,opt,name=database,proto3" json:"database,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
The request for [DropDatabase][google.spanner.admin.database.v1.DatabaseAdmin.DropDatabase].
func (*DropDatabaseRequest) Descriptor ¶
func (*DropDatabaseRequest) Descriptor() ([]byte, []int)
func (*DropDatabaseRequest) GetDatabase ¶
func (m *DropDatabaseRequest) GetDatabase() string
func (*DropDatabaseRequest) ProtoMessage ¶
func (*DropDatabaseRequest) ProtoMessage()
func (*DropDatabaseRequest) Reset ¶
func (m *DropDatabaseRequest) Reset()
func (*DropDatabaseRequest) String ¶
func (m *DropDatabaseRequest) String() string
func (*DropDatabaseRequest) XXX_DiscardUnknown ¶
func (m *DropDatabaseRequest) XXX_DiscardUnknown()
func (*DropDatabaseRequest) XXX_Marshal ¶
func (m *DropDatabaseRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*DropDatabaseRequest) XXX_Merge ¶
func (dst *DropDatabaseRequest) XXX_Merge(src proto.Message)
func (*DropDatabaseRequest) XXX_Size ¶
func (m *DropDatabaseRequest) XXX_Size() int
func (*DropDatabaseRequest) XXX_Unmarshal ¶
func (m *DropDatabaseRequest) XXX_Unmarshal(b []byte) error
type GetDatabaseDdlRequest ¶
type GetDatabaseDdlRequest struct { // Required. The database whose schema we wish to get. Database string `protobuf:"bytes,1,opt,name=database,proto3" json:"database,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
The request for [GetDatabaseDdl][google.spanner.admin.database.v1.DatabaseAdmin.GetDatabaseDdl].
func (*GetDatabaseDdlRequest) Descriptor ¶
func (*GetDatabaseDdlRequest) Descriptor() ([]byte, []int)
func (*GetDatabaseDdlRequest) GetDatabase ¶
func (m *GetDatabaseDdlRequest) GetDatabase() string
func (*GetDatabaseDdlRequest) ProtoMessage ¶
func (*GetDatabaseDdlRequest) ProtoMessage()
func (*GetDatabaseDdlRequest) Reset ¶
func (m *GetDatabaseDdlRequest) Reset()
func (*GetDatabaseDdlRequest) String ¶
func (m *GetDatabaseDdlRequest) String() string
func (*GetDatabaseDdlRequest) XXX_DiscardUnknown ¶
func (m *GetDatabaseDdlRequest) XXX_DiscardUnknown()
func (*GetDatabaseDdlRequest) XXX_Marshal ¶
func (m *GetDatabaseDdlRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GetDatabaseDdlRequest) XXX_Merge ¶
func (dst *GetDatabaseDdlRequest) XXX_Merge(src proto.Message)
func (*GetDatabaseDdlRequest) XXX_Size ¶
func (m *GetDatabaseDdlRequest) XXX_Size() int
func (*GetDatabaseDdlRequest) XXX_Unmarshal ¶
func (m *GetDatabaseDdlRequest) XXX_Unmarshal(b []byte) error
type GetDatabaseDdlResponse ¶
type GetDatabaseDdlResponse struct { // A list of formatted DDL statements defining the schema of the database // specified in the request. Statements []string `protobuf:"bytes,1,rep,name=statements,proto3" json:"statements,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
The response for [GetDatabaseDdl][google.spanner.admin.database.v1.DatabaseAdmin.GetDatabaseDdl].
func (*GetDatabaseDdlResponse) Descriptor ¶
func (*GetDatabaseDdlResponse) Descriptor() ([]byte, []int)
func (*GetDatabaseDdlResponse) GetStatements ¶
func (m *GetDatabaseDdlResponse) GetStatements() []string
func (*GetDatabaseDdlResponse) ProtoMessage ¶
func (*GetDatabaseDdlResponse) ProtoMessage()
func (*GetDatabaseDdlResponse) Reset ¶
func (m *GetDatabaseDdlResponse) Reset()
func (*GetDatabaseDdlResponse) String ¶
func (m *GetDatabaseDdlResponse) String() string
func (*GetDatabaseDdlResponse) XXX_DiscardUnknown ¶
func (m *GetDatabaseDdlResponse) XXX_DiscardUnknown()
func (*GetDatabaseDdlResponse) XXX_Marshal ¶
func (m *GetDatabaseDdlResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GetDatabaseDdlResponse) XXX_Merge ¶
func (dst *GetDatabaseDdlResponse) XXX_Merge(src proto.Message)
func (*GetDatabaseDdlResponse) XXX_Size ¶
func (m *GetDatabaseDdlResponse) XXX_Size() int
func (*GetDatabaseDdlResponse) XXX_Unmarshal ¶
func (m *GetDatabaseDdlResponse) XXX_Unmarshal(b []byte) error
type GetDatabaseRequest ¶
type GetDatabaseRequest struct { // Required. The name of the requested database. Values are of the form // `projects/<project>/instances/<instance>/databases/<database>`. Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
The request for [GetDatabase][google.spanner.admin.database.v1.DatabaseAdmin.GetDatabase].
func (*GetDatabaseRequest) Descriptor ¶
func (*GetDatabaseRequest) Descriptor() ([]byte, []int)
func (*GetDatabaseRequest) GetName ¶
func (m *GetDatabaseRequest) GetName() string
func (*GetDatabaseRequest) ProtoMessage ¶
func (*GetDatabaseRequest) ProtoMessage()
func (*GetDatabaseRequest) Reset ¶
func (m *GetDatabaseRequest) Reset()
func (*GetDatabaseRequest) String ¶
func (m *GetDatabaseRequest) String() string
func (*GetDatabaseRequest) XXX_DiscardUnknown ¶
func (m *GetDatabaseRequest) XXX_DiscardUnknown()
func (*GetDatabaseRequest) XXX_Marshal ¶
func (m *GetDatabaseRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*GetDatabaseRequest) XXX_Merge ¶
func (dst *GetDatabaseRequest) XXX_Merge(src proto.Message)
func (*GetDatabaseRequest) XXX_Size ¶
func (m *GetDatabaseRequest) XXX_Size() int
func (*GetDatabaseRequest) XXX_Unmarshal ¶
func (m *GetDatabaseRequest) XXX_Unmarshal(b []byte) error
type ListDatabasesRequest ¶
type ListDatabasesRequest struct { // Required. The instance whose databases should be listed. // Values are of the form `projects/<project>/instances/<instance>`. Parent string `protobuf:"bytes,1,opt,name=parent,proto3" json:"parent,omitempty"` // Number of databases to be returned in the response. If 0 or less, // defaults to the server's maximum allowed page size. PageSize int32 `protobuf:"varint,3,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"` // If non-empty, `page_token` should contain a // [next_page_token][google.spanner.admin.database.v1.ListDatabasesResponse.next_page_token] from a // previous [ListDatabasesResponse][google.spanner.admin.database.v1.ListDatabasesResponse]. PageToken string `protobuf:"bytes,4,opt,name=page_token,json=pageToken,proto3" json:"page_token,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
The request for [ListDatabases][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabases].
func (*ListDatabasesRequest) Descriptor ¶
func (*ListDatabasesRequest) Descriptor() ([]byte, []int)
func (*ListDatabasesRequest) GetPageSize ¶
func (m *ListDatabasesRequest) GetPageSize() int32
func (*ListDatabasesRequest) GetPageToken ¶
func (m *ListDatabasesRequest) GetPageToken() string
func (*ListDatabasesRequest) GetParent ¶
func (m *ListDatabasesRequest) GetParent() string
func (*ListDatabasesRequest) ProtoMessage ¶
func (*ListDatabasesRequest) ProtoMessage()
func (*ListDatabasesRequest) Reset ¶
func (m *ListDatabasesRequest) Reset()
func (*ListDatabasesRequest) String ¶
func (m *ListDatabasesRequest) String() string
func (*ListDatabasesRequest) XXX_DiscardUnknown ¶
func (m *ListDatabasesRequest) XXX_DiscardUnknown()
func (*ListDatabasesRequest) XXX_Marshal ¶
func (m *ListDatabasesRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ListDatabasesRequest) XXX_Merge ¶
func (dst *ListDatabasesRequest) XXX_Merge(src proto.Message)
func (*ListDatabasesRequest) XXX_Size ¶
func (m *ListDatabasesRequest) XXX_Size() int
func (*ListDatabasesRequest) XXX_Unmarshal ¶
func (m *ListDatabasesRequest) XXX_Unmarshal(b []byte) error
type ListDatabasesResponse ¶
type ListDatabasesResponse struct { // Databases that matched the request. Databases []*Database `protobuf:"bytes,1,rep,name=databases,proto3" json:"databases,omitempty"` // `next_page_token` can be sent in a subsequent // [ListDatabases][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabases] call to fetch more // of the matching databases. NextPageToken string `protobuf:"bytes,2,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
The response for [ListDatabases][google.spanner.admin.database.v1.DatabaseAdmin.ListDatabases].
func (*ListDatabasesResponse) Descriptor ¶
func (*ListDatabasesResponse) Descriptor() ([]byte, []int)
func (*ListDatabasesResponse) GetDatabases ¶
func (m *ListDatabasesResponse) GetDatabases() []*Database
func (*ListDatabasesResponse) GetNextPageToken ¶
func (m *ListDatabasesResponse) GetNextPageToken() string
func (*ListDatabasesResponse) ProtoMessage ¶
func (*ListDatabasesResponse) ProtoMessage()
func (*ListDatabasesResponse) Reset ¶
func (m *ListDatabasesResponse) Reset()
func (*ListDatabasesResponse) String ¶
func (m *ListDatabasesResponse) String() string
func (*ListDatabasesResponse) XXX_DiscardUnknown ¶
func (m *ListDatabasesResponse) XXX_DiscardUnknown()
func (*ListDatabasesResponse) XXX_Marshal ¶
func (m *ListDatabasesResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ListDatabasesResponse) XXX_Merge ¶
func (dst *ListDatabasesResponse) XXX_Merge(src proto.Message)
func (*ListDatabasesResponse) XXX_Size ¶
func (m *ListDatabasesResponse) XXX_Size() int
func (*ListDatabasesResponse) XXX_Unmarshal ¶
func (m *ListDatabasesResponse) XXX_Unmarshal(b []byte) error
type UpdateDatabaseDdlMetadata ¶
type UpdateDatabaseDdlMetadata struct { // The database being modified. Database string `protobuf:"bytes,1,opt,name=database,proto3" json:"database,omitempty"` // For an update this list contains all the statements. For an // individual statement, this list contains only that statement. Statements []string `protobuf:"bytes,2,rep,name=statements,proto3" json:"statements,omitempty"` // Reports the commit timestamps of all statements that have // succeeded so far, where `commit_timestamps[i]` is the commit // timestamp for the statement `statements[i]`. CommitTimestamps []*timestamp.Timestamp `protobuf:"bytes,3,rep,name=commit_timestamps,json=commitTimestamps,proto3" json:"commit_timestamps,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
Metadata type for the operation returned by [UpdateDatabaseDdl][google.spanner.admin.database.v1.DatabaseAdmin.UpdateDatabaseDdl].
func (*UpdateDatabaseDdlMetadata) Descriptor ¶
func (*UpdateDatabaseDdlMetadata) Descriptor() ([]byte, []int)
func (*UpdateDatabaseDdlMetadata) GetCommitTimestamps ¶
func (m *UpdateDatabaseDdlMetadata) GetCommitTimestamps() []*timestamp.Timestamp
func (*UpdateDatabaseDdlMetadata) GetDatabase ¶
func (m *UpdateDatabaseDdlMetadata) GetDatabase() string
func (*UpdateDatabaseDdlMetadata) GetStatements ¶
func (m *UpdateDatabaseDdlMetadata) GetStatements() []string
func (*UpdateDatabaseDdlMetadata) ProtoMessage ¶
func (*UpdateDatabaseDdlMetadata) ProtoMessage()
func (*UpdateDatabaseDdlMetadata) Reset ¶
func (m *UpdateDatabaseDdlMetadata) Reset()
func (*UpdateDatabaseDdlMetadata) String ¶
func (m *UpdateDatabaseDdlMetadata) String() string
func (*UpdateDatabaseDdlMetadata) XXX_DiscardUnknown ¶
func (m *UpdateDatabaseDdlMetadata) XXX_DiscardUnknown()
func (*UpdateDatabaseDdlMetadata) XXX_Marshal ¶
func (m *UpdateDatabaseDdlMetadata) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*UpdateDatabaseDdlMetadata) XXX_Merge ¶
func (dst *UpdateDatabaseDdlMetadata) XXX_Merge(src proto.Message)
func (*UpdateDatabaseDdlMetadata) XXX_Size ¶
func (m *UpdateDatabaseDdlMetadata) XXX_Size() int
func (*UpdateDatabaseDdlMetadata) XXX_Unmarshal ¶
func (m *UpdateDatabaseDdlMetadata) XXX_Unmarshal(b []byte) error
type UpdateDatabaseDdlRequest ¶
type UpdateDatabaseDdlRequest struct { // Required. The database to update. Database string `protobuf:"bytes,1,opt,name=database,proto3" json:"database,omitempty"` // DDL statements to be applied to the database. Statements []string `protobuf:"bytes,2,rep,name=statements,proto3" json:"statements,omitempty"` // If empty, the new update request is assigned an // automatically-generated operation ID. Otherwise, `operation_id` // is used to construct the name of the resulting // [Operation][google.longrunning.Operation]. // // Specifying an explicit operation ID simplifies determining // whether the statements were executed in the event that the // [UpdateDatabaseDdl][google.spanner.admin.database.v1.DatabaseAdmin.UpdateDatabaseDdl] call is replayed, // or the return value is otherwise lost: the [database][google.spanner.admin.database.v1.UpdateDatabaseDdlRequest.database] and // `operation_id` fields can be combined to form the // [name][google.longrunning.Operation.name] of the resulting // [longrunning.Operation][google.longrunning.Operation]: `<database>/operations/<operation_id>`. // // `operation_id` should be unique within the database, and must be // a valid identifier: `[a-z][a-z0-9_]*`. Note that // automatically-generated operation IDs always begin with an // underscore. If the named operation already exists, // [UpdateDatabaseDdl][google.spanner.admin.database.v1.DatabaseAdmin.UpdateDatabaseDdl] returns // `ALREADY_EXISTS`. OperationId string `protobuf:"bytes,3,opt,name=operation_id,json=operationId,proto3" json:"operation_id,omitempty"` XXX_NoUnkeyedLiteral struct{} `json:"-"` XXX_unrecognized []byte `json:"-"` XXX_sizecache int32 `json:"-"` }
Enqueues the given DDL statements to be applied, in order but not necessarily all at once, to the database schema at some point (or points) in the future. The server checks that the statements are executable (syntactically valid, name tables that exist, etc.) before enqueueing them, but they may still fail upon later execution (e.g., if a statement from another batch of statements is applied first and it conflicts in some way, or if there is some data-related problem like a `NULL` value in a column to which `NOT NULL` would be added). If a statement fails, all subsequent statements in the batch are automatically cancelled.
Each batch of statements is assigned a name which can be used with the [Operations][google.longrunning.Operations] API to monitor progress. See the [operation_id][google.spanner.admin.database.v1.UpdateDatabaseDdlRequest.operation_id] field for more details.
func (*UpdateDatabaseDdlRequest) Descriptor ¶
func (*UpdateDatabaseDdlRequest) Descriptor() ([]byte, []int)
func (*UpdateDatabaseDdlRequest) GetDatabase ¶
func (m *UpdateDatabaseDdlRequest) GetDatabase() string
func (*UpdateDatabaseDdlRequest) GetOperationId ¶
func (m *UpdateDatabaseDdlRequest) GetOperationId() string
func (*UpdateDatabaseDdlRequest) GetStatements ¶
func (m *UpdateDatabaseDdlRequest) GetStatements() []string
func (*UpdateDatabaseDdlRequest) ProtoMessage ¶
func (*UpdateDatabaseDdlRequest) ProtoMessage()
func (*UpdateDatabaseDdlRequest) Reset ¶
func (m *UpdateDatabaseDdlRequest) Reset()
func (*UpdateDatabaseDdlRequest) String ¶
func (m *UpdateDatabaseDdlRequest) String() string
func (*UpdateDatabaseDdlRequest) XXX_DiscardUnknown ¶
func (m *UpdateDatabaseDdlRequest) XXX_DiscardUnknown()
func (*UpdateDatabaseDdlRequest) XXX_Marshal ¶
func (m *UpdateDatabaseDdlRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*UpdateDatabaseDdlRequest) XXX_Merge ¶
func (dst *UpdateDatabaseDdlRequest) XXX_Merge(src proto.Message)
func (*UpdateDatabaseDdlRequest) XXX_Size ¶
func (m *UpdateDatabaseDdlRequest) XXX_Size() int
func (*UpdateDatabaseDdlRequest) XXX_Unmarshal ¶
func (m *UpdateDatabaseDdlRequest) XXX_Unmarshal(b []byte) error