usagegcs

package
v1.32.5 Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2025 License: BSD-3-Clause Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Name = "usage-gcs"
)

Variables

This section is empty.

Functions

func New

func New() *module

Types

type GCSStorage

type GCSStorage struct {
	*common.BaseStorage
	// contains filtered or unexported fields
}

GCSStorage implements the StorageBackend interface for GCS

func NewGCSStorage

func NewGCSStorage(ctx context.Context, logger logrus.FieldLogger, metrics *common.Metrics) (*GCSStorage, error)

NewGCSStorage creates a new GCS storage backend

func (*GCSStorage) Close

func (g *GCSStorage) Close() error

Close cleans up resources

func (*GCSStorage) UpdateConfig

func (g *GCSStorage) UpdateConfig(config common.StorageConfig) (bool, error)

UpdateConfig updates the backend configuration from the provided config

func (*GCSStorage) UploadUsageData

func (g *GCSStorage) UploadUsageData(ctx context.Context, usage *types.Report) error

UploadUsageData uploads the usage data to the storage backend

func (*GCSStorage) VerifyPermissions

func (g *GCSStorage) VerifyPermissions(ctx context.Context) error

VerifyPermissions checks if the backend can access the storage location

Jump to

Keyboard shortcuts

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