objectstore

package
v0.2.13 Latest Latest
Warning

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

Go to latest
Published: Dec 1, 2025 License: MIT Imports: 5 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package objectstore provides a factory function to create ObjectStore instances.

Index

Constants

View Source
const (
	DefaultDriver = "local" // Define a default driver
)
View Source
const Module = "storage.objectstore"

Variables

This section is empty.

Functions

func New

New creates a new ObjectStore instance based on the provided configuration. It uses the internal factory registry to find the appropriate provider. To use a specific provider (e.g., "minio"), ensure its package is imported for its side effects (e.g., `import _ "path/to/minio/provider"`), which will register the provider's factory.

func Register

func Register(name string, factory Factory)

Register registers a new object store factory with the default factory registry.

Types

type Factory

type Factory interface {
	New(cfg *ossv1.ObjectStoreConfig) (storageiface.ObjectStore, error) // Changed cfg type
}

Factory is the interface for creating new ObjectStore components.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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