Documentation
¶
Overview ¶
Package inmemory provides an in-memory BinaryStore implementation. Data is held only in process memory: it is not persisted to disk and does not survive a process restart, and it is not shared across multiple instances of an application. It is useful for local development, testing, and demos where a durable object storage backend is not required.
Index ¶
- func NewInMemoryBinaryStore(log logger.Logger) binarystore.BinaryStore
- type InMemoryBinaryStore
- func (s *InMemoryBinaryStore) Close() error
- func (s *InMemoryBinaryStore) Delete(_ context.Context, req *binarystore.DeleteRequest) error
- func (s *InMemoryBinaryStore) Features() []binarystore.Feature
- func (s *InMemoryBinaryStore) Get(_ context.Context, req *binarystore.GetRequest) (*binarystore.GetResponse, error)
- func (s *InMemoryBinaryStore) GetComponentMetadata() (metadataInfo metadata.MetadataMap)
- func (s *InMemoryBinaryStore) Init(_ context.Context, md binarystore.Metadata) error
- func (s *InMemoryBinaryStore) Set(_ context.Context, req *binarystore.SetRequest) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewInMemoryBinaryStore ¶
func NewInMemoryBinaryStore(log logger.Logger) binarystore.BinaryStore
NewInMemoryBinaryStore returns a new in-memory BinaryStore.
Types ¶
type InMemoryBinaryStore ¶
type InMemoryBinaryStore struct {
// contains filtered or unexported fields
}
InMemoryBinaryStore is an in-memory BinaryStore implementation.
func (*InMemoryBinaryStore) Close ¶
func (s *InMemoryBinaryStore) Close() error
func (*InMemoryBinaryStore) Delete ¶
func (s *InMemoryBinaryStore) Delete(_ context.Context, req *binarystore.DeleteRequest) error
func (*InMemoryBinaryStore) Features ¶
func (s *InMemoryBinaryStore) Features() []binarystore.Feature
func (*InMemoryBinaryStore) Get ¶
func (s *InMemoryBinaryStore) Get(_ context.Context, req *binarystore.GetRequest) (*binarystore.GetResponse, error)
func (*InMemoryBinaryStore) GetComponentMetadata ¶
func (s *InMemoryBinaryStore) GetComponentMetadata() (metadataInfo metadata.MetadataMap)
func (*InMemoryBinaryStore) Init ¶
func (s *InMemoryBinaryStore) Init(_ context.Context, md binarystore.Metadata) error
func (*InMemoryBinaryStore) Set ¶
func (s *InMemoryBinaryStore) Set(_ context.Context, req *binarystore.SetRequest) error
Click to show internal directories.
Click to hide internal directories.