Documentation ¶
Index ¶
- Constants
- Variables
- func VerifyAbsPath(absPath, adapterPath string, allowedPrefixes []string) error
- func WithAllowedExternalPrefixes(prefixes []string) func(a *Adapter)
- func WithImportEnabled(b bool) func(a *Adapter)
- func WithRemoveEmptyDir(b bool) func(a *Adapter)
- type Adapter
- func (l *Adapter) AbortMultiPartUpload(_ context.Context, obj block.ObjectPointer, uploadID string) error
- func (l *Adapter) BlockstoreType() string
- func (l *Adapter) CompleteMultiPartUpload(_ context.Context, obj block.ObjectPointer, uploadID string, ...) (*block.CompleteMultiPartUploadResponse, error)
- func (l *Adapter) Copy(_ context.Context, sourceObj, destinationObj block.ObjectPointer) error
- func (l *Adapter) CreateMultiPartUpload(_ context.Context, obj block.ObjectPointer, _ *http.Request, ...) (*block.CreateMultiPartUploadResponse, error)
- func (l *Adapter) Exists(_ context.Context, obj block.ObjectPointer) (bool, error)
- func (l *Adapter) GenerateInventory(_ context.Context, _ logging.Logger, _ string, _ bool, _ []string) (block.Inventory, error)
- func (l *Adapter) Get(_ context.Context, obj block.ObjectPointer, _ int64) (reader io.ReadCloser, err error)
- func (l *Adapter) GetPreSignedURL(_ context.Context, _ block.ObjectPointer, _ block.PreSignMode) (string, error)
- func (l *Adapter) GetProperties(_ context.Context, obj block.ObjectPointer) (block.Properties, error)
- func (l *Adapter) GetRange(_ context.Context, obj block.ObjectPointer, start int64, end int64) (io.ReadCloser, error)
- func (l *Adapter) GetStorageNamespaceInfo() block.StorageNamespaceInfo
- func (l *Adapter) GetWalker(uri *url.URL) (block.Walker, error)
- func (l *Adapter) Path() string
- func (l *Adapter) Put(_ context.Context, obj block.ObjectPointer, _ int64, reader io.Reader, ...) error
- func (l *Adapter) Remove(_ context.Context, obj block.ObjectPointer) error
- func (l *Adapter) ResolveNamespace(storageNamespace, key string, identifierType block.IdentifierType) (block.QualifiedKey, error)
- func (l *Adapter) RuntimeStats() map[string]string
- func (l *Adapter) UploadCopyPart(ctx context.Context, sourceObj, destinationObj block.ObjectPointer, ...) (*block.UploadPartResponse, error)
- func (l *Adapter) UploadCopyPartRange(ctx context.Context, sourceObj, destinationObj block.ObjectPointer, ...) (*block.UploadPartResponse, error)
- func (l *Adapter) UploadPart(ctx context.Context, obj block.ObjectPointer, _ int64, reader io.Reader, ...) (*block.UploadPartResponse, error)
- type QualifiedKey
- type Walker
Constants ¶
View Source
const (
DefaultNamespacePrefix = "local:/"
)
View Source
const StoragePrefix = block.BlockstoreTypeLocal + "://"
Variables ¶
View Source
var ( ErrPathNotWritable = errors.New("path provided is not writable") ErrInventoryNotSupported = errors.New("inventory feature not implemented for local storage adapter") ErrInvalidUploadIDFormat = errors.New("invalid upload id format") ErrBadPath = errors.New("bad path traversal blocked") )
Functions ¶
func VerifyAbsPath ¶ added in v0.97.0
func WithAllowedExternalPrefixes ¶ added in v0.94.0
func WithImportEnabled ¶ added in v0.94.0
func WithRemoveEmptyDir ¶
Types ¶
type Adapter ¶
type Adapter struct {
// contains filtered or unexported fields
}
func (*Adapter) AbortMultiPartUpload ¶
func (*Adapter) BlockstoreType ¶
func (*Adapter) CompleteMultiPartUpload ¶
func (l *Adapter) CompleteMultiPartUpload(_ context.Context, obj block.ObjectPointer, uploadID string, multipartList *block.MultipartUploadCompletion) (*block.CompleteMultiPartUploadResponse, error)
func (*Adapter) CreateMultiPartUpload ¶
func (l *Adapter) CreateMultiPartUpload(_ context.Context, obj block.ObjectPointer, _ *http.Request, _ block.CreateMultiPartUploadOpts) (*block.CreateMultiPartUploadResponse, error)
func (*Adapter) GenerateInventory ¶
func (*Adapter) Get ¶
func (l *Adapter) Get(_ context.Context, obj block.ObjectPointer, _ int64) (reader io.ReadCloser, err error)
func (*Adapter) GetPreSignedURL ¶ added in v0.90.0
func (l *Adapter) GetPreSignedURL(_ context.Context, _ block.ObjectPointer, _ block.PreSignMode) (string, error)
func (*Adapter) GetProperties ¶
func (l *Adapter) GetProperties(_ context.Context, obj block.ObjectPointer) (block.Properties, error)
func (*Adapter) GetRange ¶
func (l *Adapter) GetRange(_ context.Context, obj block.ObjectPointer, start int64, end int64) (io.ReadCloser, error)
func (*Adapter) GetStorageNamespaceInfo ¶
func (l *Adapter) GetStorageNamespaceInfo() block.StorageNamespaceInfo
func (*Adapter) ResolveNamespace ¶ added in v0.97.0
func (l *Adapter) ResolveNamespace(storageNamespace, key string, identifierType block.IdentifierType) (block.QualifiedKey, error)
func (*Adapter) RuntimeStats ¶ added in v0.41.1
func (*Adapter) UploadCopyPart ¶
func (l *Adapter) UploadCopyPart(ctx context.Context, sourceObj, destinationObj block.ObjectPointer, uploadID string, partNumber int) (*block.UploadPartResponse, error)
func (*Adapter) UploadCopyPartRange ¶
func (*Adapter) UploadPart ¶
type QualifiedKey ¶ added in v0.97.0
type QualifiedKey struct { block.CommonQualifiedKey // contains filtered or unexported fields }
func (QualifiedKey) Format ¶ added in v0.97.0
func (qk QualifiedKey) Format() string
func (QualifiedKey) GetKey ¶ added in v0.97.0
func (qk QualifiedKey) GetKey() string
func (QualifiedKey) GetStorageNamespace ¶ added in v0.97.0
func (qk QualifiedKey) GetStorageNamespace() string
func (QualifiedKey) GetStorageType ¶ added in v0.97.0
func (qk QualifiedKey) GetStorageType() block.StorageType
type Walker ¶ added in v0.97.0
type Walker struct {
// contains filtered or unexported fields
}
func NewLocalWalker ¶ added in v0.97.0
func (*Walker) GetSkippedEntries ¶ added in v0.98.0
func (l *Walker) GetSkippedEntries() []block.ObjectStoreEntry
Click to show internal directories.
Click to hide internal directories.