Documentation
¶
Overview ¶
Package azure implements bsw.BlockStorageWrapper for Azure Blob Storage.
All objects are stored in one container. The bucket is the beginning of the blob name: <container>/<bucket>/<key>, it may have several elements.
Index ¶
- Variables
- type AzureCompletedPartdeprecated
- type Config
- type Service
- func (s *Service) CompleteMultipartUpload(o *bsw.Object, uploadID string, parts []bsw.CompletedPart) error
- func (s *Service) Init(ctx context.Context) error
- func (s *Service) Name() string
- func (s *Service) PreSignGetObjectURL(o *bsw.Object, timeout time.Duration) (string, error)
- func (s *Service) PreSignMultipartObjectURL(o *bsw.Object, timeout time.Duration) ([]string, string, error)
- func (s *Service) PreSignPutObjectURL(o *bsw.Object, timeout time.Duration) (string, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrCredential = errors.Template("failed to create credential"). Code("BSW-0301").StatusCode(500).Severity(errors.Critical) ErrServiceClient = errors.Template("failed to create service client"). Code("BSW-0302").StatusCode(503).Severity(errors.Critical) ErrPresignPutURL = errors.Template("failed to create SAS put URL"). Code("BSW-0303").StatusCode(503).Severity(errors.Critical) ErrPresignGetURL = errors.Template("failed to create SAS get URL"). Code("BSW-0304").StatusCode(503).Severity(errors.Critical) )
Functions ¶
This section is empty.
Types ¶
type AzureCompletedPart
deprecated
type Config ¶
type Config struct {
AccountName string `json:"accountName"`
AccountKey string `json:"accountKey"`
ContainerName string `json:"containerName"`
// ServiceURL overrides the blob service URL, e.g. for Azurite. Optional.
// Default: https://<AccountName>.blob.core.windows.net/
ServiceURL string `json:"serviceURL"`
}
Config holds Azure Blob Storage settings.
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
Service implements bsw.BlockStorageWrapper for Azure Blob Storage.
func (*Service) CompleteMultipartUpload ¶
func (s *Service) CompleteMultipartUpload(o *bsw.Object, uploadID string, parts []bsw.CompletedPart) error
CompleteMultipartUpload is not supported yet.
func (*Service) PreSignGetObjectURL ¶
PreSignGetObjectURL returns a SAS URL for GET blob request.
Click to show internal directories.
Click to hide internal directories.