blobs

package
v0.0.0 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2024 License: Apache-2.0, MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewBlobGetHandler

func NewBlobGetHandler(blobs blobstore.Blobstore) func(http.ResponseWriter, *http.Request)

Types

type BlobService

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

func New

func New(id principal.Signer, blobStore blobstore.Blobstore, allocsDatastore datastore.Datastore, publicURL url.URL, opts ...Option) (*BlobService, error)

func (*BlobService) Access

func (b *BlobService) Access() access.Access

func (*BlobService) Allocations

func (b *BlobService) Allocations() allocationstore.AllocationStore

func (*BlobService) Presigner

func (b *BlobService) Presigner() presigner.RequestPresigner

func (*BlobService) Store

func (b *BlobService) Store() blobstore.Blobstore

type Blobs

type Blobs interface {
	// Blobs is the storage interface for blobs.
	Store() blobstore.Blobstore
	// Allocations is a store for received blob allocations.
	Allocations() allocationstore.AllocationStore
	// Presigner provides an interface to allow signed request access to upload blobs.
	Presigner() presigner.RequestPresigner
	// Access provides an interface to allowing public access to download blobs.
	Access() access.Access
}

type Option

type Option func(*options) error

func WithLogLevel

func WithLogLevel(level string) Option

WithLogLevel changes the log level for the claims subsystem.

type Server

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

func (*Server) Serve

func (srv *Server) Serve(mux *http.ServeMux)

Jump to

Keyboard shortcuts

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