Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AccessPolicy

type AccessPolicy interface {
	UpdateAccessPolicy(allowedIps, apiKey, bucketName string, rcc ResourceConfigurationV1) error
}

type AccessPolicyFactory

type AccessPolicyFactory interface {
	NewAccessPolicy() AccessPolicy
}

type COSSession

type COSSession struct {
	// contains filtered or unexported fields
}

    COSSession represents a COS (S3) session

    func (*COSSession) CheckBucketAccess

    func (s *COSSession) CheckBucketAccess(bucket string) error

      CheckBucketAccess method check that a bucket can be accessed

      func (*COSSession) CheckObjectPathExistence

      func (s *COSSession) CheckObjectPathExistence(bucket, objectpath string) (bool, error)

        CheckObjectPathExistence method checks that object-path exists inside bucket

        func (*COSSession) CreateBucket

        func (s *COSSession) CreateBucket(bucket string) (string, error)

          CreateBucket methods creates a new bucket

          func (*COSSession) DeleteBucket

          func (s *COSSession) DeleteBucket(bucket string) error

            DeleteBucket methods deletes a bucket (with all of its objects)

            type COSSessionFactory

            type COSSessionFactory struct{}

              COSSessionFactory represents a COS (S3) session factory

              func (*COSSessionFactory) NewObjectStorageSession

              func (s *COSSessionFactory) NewObjectStorageSession(endpoint, region string, creds *ObjectStorageCredentials, logger *zap.Logger) ObjectStorageSession

                NewObjectStorageSession method creates a new object store session

                type ObjectStorageCredentials

                type ObjectStorageCredentials struct {
                	// AccessKey is the account identifier in AWS authentication
                	AccessKey string
                	// SecretKey is the "password" in AWS authentication
                	SecretKey string
                	// APIKey is the "password" in IBM IAM authentication
                	APIKey string
                	// ServiceInstanceID is the account identifier in IBM IAM authentication
                	ServiceInstanceID string
                	//IAMEndpoint ...
                	IAMEndpoint string
                }

                  ObjectStorageCredentials holds credentials for accessing an object storage service

                  type ObjectStorageSession

                  type ObjectStorageSession interface {
                  
                  	// CheckBucketAccess method check that a bucket can be accessed
                  	CheckBucketAccess(bucket string) error
                  
                  	// CheckObjectPathExistence method checks that object-path exists inside bucket
                  	CheckObjectPathExistence(bucket, objectpath string) (bool, error)
                  
                  	// CreateBucket methods creates a new bucket
                  	CreateBucket(bucket string) (string, error)
                  
                  	// DeleteBucket methods deletes a bucket (with all of its objects)
                  	DeleteBucket(bucket string) error
                  }

                    ObjectStorageSession is an interface of an object store session

                    type ObjectStorageSessionFactory

                    type ObjectStorageSessionFactory interface {
                    
                    	// NewObjectStorageBackend method creates a new object store session
                    	NewObjectStorageSession(endpoint, region string, creds *ObjectStorageCredentials, logger *zap.Logger) ObjectStorageSession
                    }

                      ObjectStorageSessionFactory is an interface of an object store session factory

                      type ResourceConfigurationV1

                      type ResourceConfigurationV1 interface {
                      	// UpdateBucketConfig updates the bucket access policy configuration with given ips
                      	UpdateBucketConfig(*rc.ResourceConfigurationV1, *rc.UpdateBucketConfigOptions) (*core.DetailedResponse, error)
                      }

                      type UpdateAPFactory

                      type UpdateAPFactory struct{}

                      func (*UpdateAPFactory) NewAccessPolicy

                      func (c *UpdateAPFactory) NewAccessPolicy() AccessPolicy

                      type UpdateAPObj

                      type UpdateAPObj struct {
                      	// contains filtered or unexported fields
                      }

                      func (*UpdateAPObj) UpdateAccessPolicy

                      func (c *UpdateAPObj) UpdateAccessPolicy(allowedIps, apiKey, bucketName string, rcc ResourceConfigurationV1) error

                        UpdateAccessPolicy updates the bucket access policy configuration with given ips

                        func (*UpdateAPObj) UpdateBucketConfig

                        func (uc *UpdateAPObj) UpdateBucketConfig(service *rc.ResourceConfigurationV1, options *rc.UpdateBucketConfigOptions) (res *core.DetailedResponse, err error)

                        Directories

                        Path Synopsis