s3interfaces

package
v0.17.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 16, 2026 License: AGPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type S3ServiceInterface

type S3ServiceInterface interface {
	GenerateUploadPayload(ctx context.Context, data []byte, s3Path, filename string, metadata map[string]string) (*s3.PutObjectInput, error)
	BulkUploadFiles(ctx context.Context, payloads []*s3.PutObjectInput) ([]string, error)
	// BulkDeleteFiles returns how many deletes failed.
	BulkDeleteFiles(ctx context.Context, uploadedKeys []string) int
	// DeleteKeys deletes every key (missing keys count as deleted); an error means some are left.
	DeleteKeys(ctx context.Context, keys []string) error
	// DeletePrefix deletes every object under prefix, which must end with "/".
	DeletePrefix(ctx context.Context, prefix string) error
	// GeneratePresignedURL generates a short-lived GET URL for a given S3 key.
	// s3Key is the full object key (path + filename already joined).
	GeneratePresignedURL(ctx context.Context, s3Key string, expiry time.Duration) (string, error)
}

S3ServiceInterface defines the interface for S3 operations

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL