Documentation
¶
Overview ¶
Package tidb include resources of ucloud tidb product
See also
- API: https://docs.ucloud.cn/api/tidb-api/index
- Product: https://www.ucloud.cn/site/product/tidb.html
for detail.
Index ¶
- type CreateTiDBServiceRequest
- type CreateTiDBServiceResponse
- type DeleteTiDBServiceRequest
- type DeleteTiDBServiceResponse
- type ServiceID
- type SetTiDBConfigParamConfigs
- type SetTiDBConfigRequest
- type SetTiDBConfigResponse
- type TiDBClient
- func (c *TiDBClient) CreateTiDBService(req *CreateTiDBServiceRequest) (*CreateTiDBServiceResponse, error)
- func (c *TiDBClient) DeleteTiDBService(req *DeleteTiDBServiceRequest) (*DeleteTiDBServiceResponse, error)
- func (c *TiDBClient) NewCreateTiDBServiceRequest() *CreateTiDBServiceRequest
- func (c *TiDBClient) NewDeleteTiDBServiceRequest() *DeleteTiDBServiceRequest
- func (c *TiDBClient) NewSetTiDBConfigRequest() *SetTiDBConfigRequest
- func (c *TiDBClient) SetTiDBConfig(req *SetTiDBConfigRequest) (*SetTiDBConfigResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CreateTiDBServiceRequest ¶
type CreateTiDBServiceRequest struct { request.CommonBase // 容灾类型:10:同可用区,20:跨可用区,默认是同可用区 DTType *string `required:"false"` // ipv4 Ip *string `required:"false"` // 服务名称, 长度不超过64 Name *string `required:"true"` // 服务root账号的密码, 长度不超过32 Password *string `required:"true"` // 端口 Port *string `required:"false"` // 子网 ID SubnetId *string `required:"true"` // 实例类型: 0: 旗舰版,30: 体验版,60: 轻量版 TikvMemoryHardTh *string `required:"false"` // VPC ID VPCId *string `required:"true"` }
CreateTiDBServiceRequest is request schema for CreateTiDBService action
type CreateTiDBServiceResponse ¶
type CreateTiDBServiceResponse struct { response.CommonBase // Service Data Data ServiceID // 返回信息 Message string // 服务ID ServiceId string }
CreateTiDBServiceResponse is response schema for CreateTiDBService action
type DeleteTiDBServiceRequest ¶
type DeleteTiDBServiceRequest struct { request.CommonBase // 资源ID Id *string `required:"true"` }
DeleteTiDBServiceRequest is request schema for DeleteTiDBService action
type DeleteTiDBServiceResponse ¶
type DeleteTiDBServiceResponse struct { response.CommonBase // 返回信息 Message string // ServiceId ServiceId string }
DeleteTiDBServiceResponse is response schema for DeleteTiDBService action
type SetTiDBConfigParamConfigs ¶
type SetTiDBConfigParamConfigs struct { // 修改的参数名: proxysql_mysql-max_connections:类型:string, 描述: 所有用户总共的最大连接数 。proxysql_max_connections: 类型:string, 描述: 每个用户的最大连接数。tidb_gc: 类型:string, 描述: tikv_gc_life_time。 Name *string `required:"true"` // 对应修改的参数值: string Value *string `required:"true"` }
SetTiDBConfigParamConfigs is request schema for complex param
type SetTiDBConfigRequest ¶
type SetTiDBConfigRequest struct { request.CommonBase // Configs []SetTiDBConfigParamConfigs `required:"false"` // 资源Id Id *string `required:"true"` }
SetTiDBConfigRequest is request schema for SetTiDBConfig action
type SetTiDBConfigResponse ¶
type SetTiDBConfigResponse struct { response.CommonBase // ServiceId ServiceId string }
SetTiDBConfigResponse is response schema for SetTiDBConfig action
type TiDBClient ¶
TiDBClient is the client of TiDB
func NewClient ¶
func NewClient(config *ucloud.Config, credential *auth.Credential) *TiDBClient
NewClient will return a instance of TiDBClient
func (*TiDBClient) CreateTiDBService ¶
func (c *TiDBClient) CreateTiDBService(req *CreateTiDBServiceRequest) (*CreateTiDBServiceResponse, error)
API: CreateTiDBService
创建TiDB服务
func (*TiDBClient) DeleteTiDBService ¶
func (c *TiDBClient) DeleteTiDBService(req *DeleteTiDBServiceRequest) (*DeleteTiDBServiceResponse, error)
API: DeleteTiDBService
删除一个服务
func (*TiDBClient) NewCreateTiDBServiceRequest ¶
func (c *TiDBClient) NewCreateTiDBServiceRequest() *CreateTiDBServiceRequest
NewCreateTiDBServiceRequest will create request of CreateTiDBService action.
func (*TiDBClient) NewDeleteTiDBServiceRequest ¶
func (c *TiDBClient) NewDeleteTiDBServiceRequest() *DeleteTiDBServiceRequest
NewDeleteTiDBServiceRequest will create request of DeleteTiDBService action.
func (*TiDBClient) NewSetTiDBConfigRequest ¶
func (c *TiDBClient) NewSetTiDBConfigRequest() *SetTiDBConfigRequest
NewSetTiDBConfigRequest will create request of SetTiDBConfig action.
func (*TiDBClient) SetTiDBConfig ¶
func (c *TiDBClient) SetTiDBConfig(req *SetTiDBConfigRequest) (*SetTiDBConfigResponse, error)
API: SetTiDBConfig
设置TiDB服务实例参数