Documentation ¶
Index ¶
- type MetadataClient
- func (client *MetadataClient) Close() error
- func (client *MetadataClient) GetBucketByBucketID(ctx context.Context, in *metatypes.GetBucketByBucketIDRequest, ...) (*metatypes.GetBucketByBucketIDResponse, error)
- func (client *MetadataClient) GetBucketByBucketName(ctx context.Context, in *metatypes.GetBucketByBucketNameRequest, ...) (*metatypes.GetBucketByBucketNameResponse, error)
- func (client *MetadataClient) GetObjectByObjectNameAndBucketName(ctx context.Context, in *metatypes.GetObjectByObjectNameAndBucketNameRequest, ...) (*metatypes.GetObjectByObjectNameAndBucketNameResponse, error)
- func (client *MetadataClient) GetPaymentByBucketID(ctx context.Context, in *metatypes.GetPaymentByBucketIDRequest, ...) (*metatypes.GetPaymentByBucketIDResponse, error)
- func (client *MetadataClient) GetPaymentByBucketName(ctx context.Context, in *metatypes.GetPaymentByBucketNameRequest, ...) (*metatypes.GetPaymentByBucketNameResponse, error)
- func (client *MetadataClient) GetUserBuckets(ctx context.Context, in *metatypes.GetUserBucketsRequest, ...) (*metatypes.GetUserBucketsResponse, error)
- func (client *MetadataClient) GetUserBucketsCount(ctx context.Context, in *metatypes.GetUserBucketsCountRequest, ...) (*metatypes.GetUserBucketsCountResponse, error)
- func (client *MetadataClient) ListDeletedObjectsByBlockNumberRange(ctx context.Context, in *metatypes.ListDeletedObjectsByBlockNumberRangeRequest, ...) (*metatypes.ListDeletedObjectsByBlockNumberRangeResponse, error)
- func (client *MetadataClient) ListExpiredBucketsBySp(ctx context.Context, createAt int64, primarySpAddress string, limit int64, ...) ([]*metatypes.Bucket, error)
- func (client *MetadataClient) ListObjectsByBucketName(ctx context.Context, in *metatypes.ListObjectsByBucketNameRequest, ...) (*metatypes.ListObjectsByBucketNameResponse, error)
- func (client *MetadataClient) VerifyPermission(ctx context.Context, in *storagetypes.QueryVerifyPermissionRequest, ...) (*storagetypes.QueryVerifyPermissionResponse, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MetadataClient ¶
type MetadataClient struct {
// contains filtered or unexported fields
}
MetadataClient is an metadata gRPC service client wrapper
func NewMetadataClient ¶
func NewMetadataClient(address string) (*MetadataClient, error)
NewMetadataClient return an MetadataClient instance
func (*MetadataClient) Close ¶
func (client *MetadataClient) Close() error
Close the metadata gPRC client connection
func (*MetadataClient) GetBucketByBucketID ¶
func (client *MetadataClient) GetBucketByBucketID(ctx context.Context, in *metatypes.GetBucketByBucketIDRequest, opts ...grpc.CallOption) (*metatypes.GetBucketByBucketIDResponse, error)
GetBucketByBucketID get bucket info by a bucket id
func (*MetadataClient) GetBucketByBucketName ¶
func (client *MetadataClient) GetBucketByBucketName(ctx context.Context, in *metatypes.GetBucketByBucketNameRequest, opts ...grpc.CallOption) (*metatypes.GetBucketByBucketNameResponse, error)
GetBucketByBucketName get bucket info by a bucket name
func (*MetadataClient) GetObjectByObjectNameAndBucketName ¶ added in v0.1.1
func (client *MetadataClient) GetObjectByObjectNameAndBucketName(ctx context.Context, in *metatypes.GetObjectByObjectNameAndBucketNameRequest, opts ...grpc.CallOption) (*metatypes.GetObjectByObjectNameAndBucketNameResponse, error)
GetObjectByObjectNameAndBucketName get object info by an object name and a bucket name
func (*MetadataClient) GetPaymentByBucketID ¶
func (client *MetadataClient) GetPaymentByBucketID(ctx context.Context, in *metatypes.GetPaymentByBucketIDRequest, opts ...grpc.CallOption) (*metatypes.GetPaymentByBucketIDResponse, error)
GetPaymentByBucketID get bucket payment info by a bucket id
func (*MetadataClient) GetPaymentByBucketName ¶
func (client *MetadataClient) GetPaymentByBucketName(ctx context.Context, in *metatypes.GetPaymentByBucketNameRequest, opts ...grpc.CallOption) (*metatypes.GetPaymentByBucketNameResponse, error)
GetPaymentByBucketName get bucket payment info by a bucket name
func (*MetadataClient) GetUserBuckets ¶
func (client *MetadataClient) GetUserBuckets(ctx context.Context, in *metatypes.GetUserBucketsRequest, opts ...grpc.CallOption) (*metatypes.GetUserBucketsResponse, error)
GetUserBuckets get buckets info by a user address
func (*MetadataClient) GetUserBucketsCount ¶
func (client *MetadataClient) GetUserBucketsCount(ctx context.Context, in *metatypes.GetUserBucketsCountRequest, opts ...grpc.CallOption) (*metatypes.GetUserBucketsCountResponse, error)
GetUserBucketsCount get buckets count by a user address
func (*MetadataClient) ListDeletedObjectsByBlockNumberRange ¶
func (client *MetadataClient) ListDeletedObjectsByBlockNumberRange(ctx context.Context, in *metatypes.ListDeletedObjectsByBlockNumberRangeRequest, opts ...grpc.CallOption) (*metatypes.ListDeletedObjectsByBlockNumberRangeResponse, error)
ListDeletedObjectsByBlockNumberRange list deleted objects info by a block range
func (*MetadataClient) ListExpiredBucketsBySp ¶ added in v0.1.2
func (client *MetadataClient) ListExpiredBucketsBySp(ctx context.Context, createAt int64, primarySpAddress string, limit int64, opts ...grpc.CallOption) ([]*metatypes.Bucket, error)
ListExpiredBucketsBySp list buckets that are expired by specific sp
func (*MetadataClient) ListObjectsByBucketName ¶
func (client *MetadataClient) ListObjectsByBucketName(ctx context.Context, in *metatypes.ListObjectsByBucketNameRequest, opts ...grpc.CallOption) (*metatypes.ListObjectsByBucketNameResponse, error)
ListObjectsByBucketName list objects info by a bucket name
func (*MetadataClient) VerifyPermission ¶ added in v0.1.2
func (client *MetadataClient) VerifyPermission(ctx context.Context, in *storagetypes.QueryVerifyPermissionRequest, opts ...grpc.CallOption) (*storagetypes.QueryVerifyPermissionResponse, error)
VerifyPermission Verify the input account’s permission to input items