Documentation ¶
Index ¶
- Constants
- func GenReqDefForBatchWriteKv() *def.HttpRequestDef
- func GenReqDefForCheckHealth() *def.HttpRequestDef
- func GenReqDefForCreateTable() *def.HttpRequestDef
- func GenReqDefForDeleteKv() *def.HttpRequestDef
- func GenReqDefForDescribeTable() *def.HttpRequestDef
- func GenReqDefForGetKv() *def.HttpRequestDef
- func GenReqDefForListStore() *def.HttpRequestDef
- func GenReqDefForListTable() *def.HttpRequestDef
- func GenReqDefForPutKv() *def.HttpRequestDef
- func GenReqDefForScanKv() *def.HttpRequestDef
- func GenReqDefForScanSkeyKv() *def.HttpRequestDef
- func GenReqDefForUpdateKv() *def.HttpRequestDef
- func GetIamEndpoint() string
- func KvsClientBuilder() *httpclient.HcHttpClientBuilder
- type BatchWriteKvInvoker
- type CheckHealthInvoker
- type CreateTableInvoker
- type DeleteKvInvoker
- type DescribeTableInvoker
- type GetKvInvoker
- type KvsClient
- func (c *KvsClient) BatchWriteKv(request *model.BatchWriteKvRequest) (*model.BatchWriteKvResponse, error)
- func (c *KvsClient) BatchWriteKvInvoker(request *model.BatchWriteKvRequest) *BatchWriteKvInvoker
- func (c *KvsClient) CheckHealth(request *model.CheckHealthRequest) (*model.CheckHealthResponse, error)
- func (c *KvsClient) CheckHealthInvoker(request *model.CheckHealthRequest) *CheckHealthInvoker
- func (c *KvsClient) CreateTable(request *model.CreateTableRequest) (*model.CreateTableResponse, error)
- func (c *KvsClient) CreateTableInvoker(request *model.CreateTableRequest) *CreateTableInvoker
- func (c *KvsClient) DeleteKv(request *model.DeleteKvRequest) (*model.DeleteKvResponse, error)
- func (c *KvsClient) DeleteKvInvoker(request *model.DeleteKvRequest) *DeleteKvInvoker
- func (c *KvsClient) DescribeTable(request *model.DescribeTableRequest) (*model.DescribeTableResponse, error)
- func (c *KvsClient) DescribeTableInvoker(request *model.DescribeTableRequest) *DescribeTableInvoker
- func (c *KvsClient) GetKv(request *model.GetKvRequest) (*model.GetKvResponse, error)
- func (c *KvsClient) GetKvInvoker(request *model.GetKvRequest) *GetKvInvoker
- func (c *KvsClient) ListStore(request *model.ListStoreRequest) (*model.ListStoreResponse, error)
- func (c *KvsClient) ListStoreInvoker(request *model.ListStoreRequest) *ListStoreInvoker
- func (c *KvsClient) ListTable(request *model.ListTableRequest) (*model.ListTableResponse, error)
- func (c *KvsClient) ListTableInvoker(request *model.ListTableRequest) *ListTableInvoker
- func (c *KvsClient) PutKv(request *model.PutKvRequest) (*model.PutKvResponse, error)
- func (c *KvsClient) PutKvInvoker(request *model.PutKvRequest) *PutKvInvoker
- func (c *KvsClient) ScanKv(request *model.ScanKvRequest) (*model.ScanKvResponse, error)
- func (c *KvsClient) ScanKvInvoker(request *model.ScanKvRequest) *ScanKvInvoker
- func (c *KvsClient) ScanSkeyKv(request *model.ScanSkeyKvRequest) (*model.ScanSkeyKvResponse, error)
- func (c *KvsClient) ScanSkeyKvInvoker(request *model.ScanSkeyKvRequest) *ScanSkeyKvInvoker
- func (c *KvsClient) UpdateKv(request *model.UpdateKvRequest) (*model.UpdateKvResponse, error)
- func (c *KvsClient) UpdateKvInvoker(request *model.UpdateKvRequest) *UpdateKvInvoker
- type KvsCredentials
- type KvsCredentialsBuilder
- func (builder *KvsCredentialsBuilder) SafeBuild() (*KvsCredentials, error)
- func (builder *KvsCredentialsBuilder) WithAk(ak string) *KvsCredentialsBuilder
- func (builder *KvsCredentialsBuilder) WithDerivedPredicate(derivedPredicate func(*request.DefaultHttpRequest) bool) *KvsCredentialsBuilder
- func (builder *KvsCredentialsBuilder) WithEnableBodySignature(enableBodySignature bool) *KvsCredentialsBuilder
- func (builder *KvsCredentialsBuilder) WithIamEndpointOverride(endpoint string) *KvsCredentialsBuilder
- func (builder *KvsCredentialsBuilder) WithIdTokenFile(idTokenFile string) *KvsCredentialsBuilder
- func (builder *KvsCredentialsBuilder) WithIdpId(idpId string) *KvsCredentialsBuilder
- func (builder *KvsCredentialsBuilder) WithProjectId(projectId string) *KvsCredentialsBuilder
- func (builder *KvsCredentialsBuilder) WithSecurityToken(token string) *KvsCredentialsBuilder
- func (builder *KvsCredentialsBuilder) WithSk(sk string) *KvsCredentialsBuilder
- type ListStoreInvoker
- type ListTableInvoker
- type PutKvInvoker
- type ScanKvInvoker
- type ScanSkeyKvInvoker
- type UpdateKvInvoker
Constants ¶
const ( DefaultIamEndpoint = "https://iam.myhuaweicloud.com" IamEndpointEnv = "HUAWEICLOUD_SDK_IAM_ENDPOINT" )
Variables ¶
This section is empty.
Functions ¶
func GenReqDefForBatchWriteKv ¶
func GenReqDefForBatchWriteKv() *def.HttpRequestDef
func GenReqDefForCheckHealth ¶ added in v0.1.121
func GenReqDefForCheckHealth() *def.HttpRequestDef
func GenReqDefForCreateTable ¶
func GenReqDefForCreateTable() *def.HttpRequestDef
func GenReqDefForDeleteKv ¶
func GenReqDefForDeleteKv() *def.HttpRequestDef
func GenReqDefForDescribeTable ¶
func GenReqDefForDescribeTable() *def.HttpRequestDef
func GenReqDefForGetKv ¶
func GenReqDefForGetKv() *def.HttpRequestDef
func GenReqDefForListStore ¶
func GenReqDefForListStore() *def.HttpRequestDef
func GenReqDefForListTable ¶
func GenReqDefForListTable() *def.HttpRequestDef
func GenReqDefForPutKv ¶
func GenReqDefForPutKv() *def.HttpRequestDef
func GenReqDefForScanKv ¶
func GenReqDefForScanKv() *def.HttpRequestDef
func GenReqDefForScanSkeyKv ¶
func GenReqDefForScanSkeyKv() *def.HttpRequestDef
func GenReqDefForUpdateKv ¶
func GenReqDefForUpdateKv() *def.HttpRequestDef
func GetIamEndpoint ¶
func GetIamEndpoint() string
func KvsClientBuilder ¶
func KvsClientBuilder() *httpclient.HcHttpClientBuilder
Types ¶
type BatchWriteKvInvoker ¶
type BatchWriteKvInvoker struct {
*invoker.BaseInvoker
}
func (*BatchWriteKvInvoker) GetBaseInvoker ¶ added in v0.1.118
func (i *BatchWriteKvInvoker) GetBaseInvoker() *invoker.BaseInvoker
func (*BatchWriteKvInvoker) Invoke ¶
func (i *BatchWriteKvInvoker) Invoke() (*model.BatchWriteKvResponse, error)
type CheckHealthInvoker ¶ added in v0.1.121
type CheckHealthInvoker struct {
*invoker.BaseInvoker
}
func (*CheckHealthInvoker) GetBaseInvoker ¶ added in v0.1.121
func (i *CheckHealthInvoker) GetBaseInvoker() *invoker.BaseInvoker
func (*CheckHealthInvoker) Invoke ¶ added in v0.1.121
func (i *CheckHealthInvoker) Invoke() (*model.CheckHealthResponse, error)
type CreateTableInvoker ¶
type CreateTableInvoker struct {
*invoker.BaseInvoker
}
func (*CreateTableInvoker) GetBaseInvoker ¶ added in v0.1.118
func (i *CreateTableInvoker) GetBaseInvoker() *invoker.BaseInvoker
func (*CreateTableInvoker) Invoke ¶
func (i *CreateTableInvoker) Invoke() (*model.CreateTableResponse, error)
type DeleteKvInvoker ¶
type DeleteKvInvoker struct {
*invoker.BaseInvoker
}
func (*DeleteKvInvoker) GetBaseInvoker ¶ added in v0.1.118
func (i *DeleteKvInvoker) GetBaseInvoker() *invoker.BaseInvoker
func (*DeleteKvInvoker) Invoke ¶
func (i *DeleteKvInvoker) Invoke() (*model.DeleteKvResponse, error)
type DescribeTableInvoker ¶
type DescribeTableInvoker struct {
*invoker.BaseInvoker
}
func (*DescribeTableInvoker) GetBaseInvoker ¶ added in v0.1.118
func (i *DescribeTableInvoker) GetBaseInvoker() *invoker.BaseInvoker
func (*DescribeTableInvoker) Invoke ¶
func (i *DescribeTableInvoker) Invoke() (*model.DescribeTableResponse, error)
type GetKvInvoker ¶
type GetKvInvoker struct {
*invoker.BaseInvoker
}
func (*GetKvInvoker) GetBaseInvoker ¶ added in v0.1.118
func (i *GetKvInvoker) GetBaseInvoker() *invoker.BaseInvoker
func (*GetKvInvoker) Invoke ¶
func (i *GetKvInvoker) Invoke() (*model.GetKvResponse, error)
type KvsClient ¶
type KvsClient struct {
HcClient *httpclient.HcHttpClient
}
func NewKvsClient ¶
func NewKvsClient(hcClient *httpclient.HcHttpClient) *KvsClient
func (*KvsClient) BatchWriteKv ¶
func (c *KvsClient) BatchWriteKv(request *model.BatchWriteKvRequest) (*model.BatchWriteKvResponse, error)
BatchWriteKv 批量写请求
批量写请求,其中可以携带一或多个表的不同kv的写操作,上传kv/删除kv。
Please refer to HUAWEI cloud API Explorer for details.
func (*KvsClient) BatchWriteKvInvoker ¶
func (c *KvsClient) BatchWriteKvInvoker(request *model.BatchWriteKvRequest) *BatchWriteKvInvoker
BatchWriteKvInvoker 批量写请求
func (*KvsClient) CheckHealth ¶ added in v0.1.121
func (c *KvsClient) CheckHealth(request *model.CheckHealthRequest) (*model.CheckHealthResponse, error)
CheckHealth 网络信道健康检查
网络信道健康检查,返回response未抛出网络异常即为成功
Please refer to HUAWEI cloud API Explorer for details.
func (*KvsClient) CheckHealthInvoker ¶ added in v0.1.121
func (c *KvsClient) CheckHealthInvoker(request *model.CheckHealthRequest) *CheckHealthInvoker
CheckHealthInvoker 网络信道健康检查
func (*KvsClient) CreateTable ¶
func (c *KvsClient) CreateTable(request *model.CreateTableRequest) (*model.CreateTableResponse, error)
CreateTable 创建表
在指定仓内创建表,表名在仓内唯一;创建表时,指定主键模板及本地二级索引模板及全局二级索引模板。创建表时,如果仓不存在,将会自动创建仓。
Please refer to HUAWEI cloud API Explorer for details.
func (*KvsClient) CreateTableInvoker ¶
func (c *KvsClient) CreateTableInvoker(request *model.CreateTableRequest) *CreateTableInvoker
CreateTableInvoker 创建表
func (*KvsClient) DeleteKv ¶
func (c *KvsClient) DeleteKv(request *model.DeleteKvRequest) (*model.DeleteKvResponse, error)
DeleteKv 删除单个kv
指定表,指定主键,删除该文档;允许指定条件执行。
Please refer to HUAWEI cloud API Explorer for details.
func (*KvsClient) DeleteKvInvoker ¶
func (c *KvsClient) DeleteKvInvoker(request *model.DeleteKvRequest) *DeleteKvInvoker
DeleteKvInvoker 删除单个kv
func (*KvsClient) DescribeTable ¶
func (c *KvsClient) DescribeTable(request *model.DescribeTableRequest) (*model.DescribeTableResponse, error)
DescribeTable 查询表
指定仓查询表属性,如容量,规模,配额。
Please refer to HUAWEI cloud API Explorer for details.
func (*KvsClient) DescribeTableInvoker ¶
func (c *KvsClient) DescribeTableInvoker(request *model.DescribeTableRequest) *DescribeTableInvoker
DescribeTableInvoker 查询表
func (*KvsClient) GetKv ¶
func (c *KvsClient) GetKv(request *model.GetKvRequest) (*model.GetKvResponse, error)
GetKv 查询单个kv
下载一个kv文档的全部内容,或者部分字段的内容。
Please refer to HUAWEI cloud API Explorer for details.
func (*KvsClient) GetKvInvoker ¶
func (c *KvsClient) GetKvInvoker(request *model.GetKvRequest) *GetKvInvoker
GetKvInvoker 查询单个kv
func (*KvsClient) ListStore ¶
func (c *KvsClient) ListStore(request *model.ListStoreRequest) (*model.ListStoreResponse, error)
ListStore 列举仓
一个账户下可以创建最多25个仓,每个仓可以创建最多100个store,响应中一次性返回所有仓名称。
Please refer to HUAWEI cloud API Explorer for details.
func (*KvsClient) ListStoreInvoker ¶
func (c *KvsClient) ListStoreInvoker(request *model.ListStoreRequest) *ListStoreInvoker
ListStoreInvoker 列举仓
func (*KvsClient) ListTable ¶
func (c *KvsClient) ListTable(request *model.ListTableRequest) (*model.ListTableResponse, error)
ListTable 列举表
指定仓列举创建的所有表。
Please refer to HUAWEI cloud API Explorer for details.
func (*KvsClient) ListTableInvoker ¶
func (c *KvsClient) ListTableInvoker(request *model.ListTableRequest) *ListTableInvoker
ListTableInvoker 列举表
func (*KvsClient) PutKv ¶
func (c *KvsClient) PutKv(request *model.PutKvRequest) (*model.PutKvResponse, error)
PutKv 上传单个kv
指定表,新建kv或覆盖已有kv,且满足表的key schema描述;允许指定条件执行。
Please refer to HUAWEI cloud API Explorer for details.
func (*KvsClient) PutKvInvoker ¶
func (c *KvsClient) PutKvInvoker(request *model.PutKvRequest) *PutKvInvoker
PutKvInvoker 上传单个kv
func (*KvsClient) ScanKv ¶
func (c *KvsClient) ScanKv(request *model.ScanKvRequest) (*model.ScanKvResponse, error)
ScanKv 扫描所有kv
指定表,扫描表下所有kv;允许指定过滤条件。
Please refer to HUAWEI cloud API Explorer for details.
func (*KvsClient) ScanKvInvoker ¶
func (c *KvsClient) ScanKvInvoker(request *model.ScanKvRequest) *ScanKvInvoker
ScanKvInvoker 扫描所有kv
func (*KvsClient) ScanSkeyKv ¶
func (c *KvsClient) ScanSkeyKv(request *model.ScanSkeyKvRequest) (*model.ScanSkeyKvResponse, error)
ScanSkeyKv 扫描分区键内kv
指定表及分区键,携带条件查询kv;允许指定过滤条件。
Please refer to HUAWEI cloud API Explorer for details.
func (*KvsClient) ScanSkeyKvInvoker ¶
func (c *KvsClient) ScanSkeyKvInvoker(request *model.ScanSkeyKvRequest) *ScanSkeyKvInvoker
ScanSkeyKvInvoker 扫描分区键内kv
func (*KvsClient) UpdateKv ¶
func (c *KvsClient) UpdateKv(request *model.UpdateKvRequest) (*model.UpdateKvResponse, error)
UpdateKv 更新单个kv
指定表,指定主键,指定更新文档的部分内容,如果是自描述文档,指定字段名;如果是二进制文档,指定偏移位置和长度;允许指定条件执行。
Please refer to HUAWEI cloud API Explorer for details.
func (*KvsClient) UpdateKvInvoker ¶
func (c *KvsClient) UpdateKvInvoker(request *model.UpdateKvRequest) *UpdateKvInvoker
UpdateKvInvoker 更新单个kv
type KvsCredentials ¶
type KvsCredentials struct { basic.Credentials // contains filtered or unexported fields }
func (*KvsCredentials) ProcessAuthRequest ¶
func (s *KvsCredentials) ProcessAuthRequest(client *impl.DefaultHttpClient, req *request.DefaultHttpRequest) (*request.DefaultHttpRequest, error)
type KvsCredentialsBuilder ¶
type KvsCredentialsBuilder struct { Credentials *KvsCredentials // contains filtered or unexported fields }
func NewKvsCredentialsBuilder ¶
func NewKvsCredentialsBuilder() *KvsCredentialsBuilder
func (*KvsCredentialsBuilder) SafeBuild ¶
func (builder *KvsCredentialsBuilder) SafeBuild() (*KvsCredentials, error)
func (*KvsCredentialsBuilder) WithAk ¶
func (builder *KvsCredentialsBuilder) WithAk(ak string) *KvsCredentialsBuilder
func (*KvsCredentialsBuilder) WithDerivedPredicate ¶
func (builder *KvsCredentialsBuilder) WithDerivedPredicate(derivedPredicate func(*request.DefaultHttpRequest) bool) *KvsCredentialsBuilder
func (*KvsCredentialsBuilder) WithEnableBodySignature ¶
func (builder *KvsCredentialsBuilder) WithEnableBodySignature(enableBodySignature bool) *KvsCredentialsBuilder
func (*KvsCredentialsBuilder) WithIamEndpointOverride ¶
func (builder *KvsCredentialsBuilder) WithIamEndpointOverride(endpoint string) *KvsCredentialsBuilder
func (*KvsCredentialsBuilder) WithIdTokenFile ¶
func (builder *KvsCredentialsBuilder) WithIdTokenFile(idTokenFile string) *KvsCredentialsBuilder
func (*KvsCredentialsBuilder) WithIdpId ¶
func (builder *KvsCredentialsBuilder) WithIdpId(idpId string) *KvsCredentialsBuilder
func (*KvsCredentialsBuilder) WithProjectId ¶
func (builder *KvsCredentialsBuilder) WithProjectId(projectId string) *KvsCredentialsBuilder
func (*KvsCredentialsBuilder) WithSecurityToken ¶
func (builder *KvsCredentialsBuilder) WithSecurityToken(token string) *KvsCredentialsBuilder
func (*KvsCredentialsBuilder) WithSk ¶
func (builder *KvsCredentialsBuilder) WithSk(sk string) *KvsCredentialsBuilder
type ListStoreInvoker ¶
type ListStoreInvoker struct {
*invoker.BaseInvoker
}
func (*ListStoreInvoker) GetBaseInvoker ¶ added in v0.1.118
func (i *ListStoreInvoker) GetBaseInvoker() *invoker.BaseInvoker
func (*ListStoreInvoker) Invoke ¶
func (i *ListStoreInvoker) Invoke() (*model.ListStoreResponse, error)
type ListTableInvoker ¶
type ListTableInvoker struct {
*invoker.BaseInvoker
}
func (*ListTableInvoker) GetBaseInvoker ¶ added in v0.1.118
func (i *ListTableInvoker) GetBaseInvoker() *invoker.BaseInvoker
func (*ListTableInvoker) Invoke ¶
func (i *ListTableInvoker) Invoke() (*model.ListTableResponse, error)
type PutKvInvoker ¶
type PutKvInvoker struct {
*invoker.BaseInvoker
}
func (*PutKvInvoker) GetBaseInvoker ¶ added in v0.1.118
func (i *PutKvInvoker) GetBaseInvoker() *invoker.BaseInvoker
func (*PutKvInvoker) Invoke ¶
func (i *PutKvInvoker) Invoke() (*model.PutKvResponse, error)
type ScanKvInvoker ¶
type ScanKvInvoker struct {
*invoker.BaseInvoker
}
func (*ScanKvInvoker) GetBaseInvoker ¶ added in v0.1.118
func (i *ScanKvInvoker) GetBaseInvoker() *invoker.BaseInvoker
func (*ScanKvInvoker) Invoke ¶
func (i *ScanKvInvoker) Invoke() (*model.ScanKvResponse, error)
type ScanSkeyKvInvoker ¶
type ScanSkeyKvInvoker struct {
*invoker.BaseInvoker
}
func (*ScanSkeyKvInvoker) GetBaseInvoker ¶ added in v0.1.118
func (i *ScanSkeyKvInvoker) GetBaseInvoker() *invoker.BaseInvoker
func (*ScanSkeyKvInvoker) Invoke ¶
func (i *ScanSkeyKvInvoker) Invoke() (*model.ScanSkeyKvResponse, error)
type UpdateKvInvoker ¶
type UpdateKvInvoker struct {
*invoker.BaseInvoker
}
func (*UpdateKvInvoker) GetBaseInvoker ¶ added in v0.1.118
func (i *UpdateKvInvoker) GetBaseInvoker() *invoker.BaseInvoker
func (*UpdateKvInvoker) Invoke ¶
func (i *UpdateKvInvoker) Invoke() (*model.UpdateKvResponse, error)