internal

package
v2.7.10 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2024 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewDurableQueueManager

func NewDurableQueueManager(log *zap.Logger, queuePath string, metrics *metrics.ReplicationsMetrics, configStore remotewrite.HttpConfigStore) *durableQueueManager

NewDurableQueueManager creates a new durableQueueManager struct, for managing durable queues associated with replication streams.

func NewValidator

func NewValidator() *noopWriteValidator

Types

type Store

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

func NewStore

func NewStore(sqlStore *sqlite.SqlStore) *Store

func (*Store) CreateReplication

func (s *Store) CreateReplication(ctx context.Context, newID platform.ID, request influxdb.CreateReplicationRequest) (*influxdb.Replication, error)

CreateReplication persists a new replication in the database. Caller is responsible for managing locks.

func (*Store) DeleteBucketReplications

func (s *Store) DeleteBucketReplications(ctx context.Context, localBucketID platform.ID) ([]platform.ID, error)

DeleteBucketReplications deletes the replications for the provided localBucketID from the database. Caller is responsible for managing locks. A list of deleted IDs is returned for further processing by the caller.

func (*Store) DeleteReplication

func (s *Store) DeleteReplication(ctx context.Context, id platform.ID) error

DeleteReplication deletes a replication by ID from the database. Caller is responsible for managing locks.

func (*Store) GetFullHTTPConfig

func (s *Store) GetFullHTTPConfig(ctx context.Context, id platform.ID) (*influxdb.ReplicationHTTPConfig, error)

func (*Store) GetReplication

func (s *Store) GetReplication(ctx context.Context, id platform.ID) (*influxdb.Replication, error)

GetReplication gets a replication by ID from the database.

func (*Store) ListReplications

func (s *Store) ListReplications(ctx context.Context, filter influxdb.ReplicationListFilter) (*influxdb.Replications, error)

ListReplications returns a list of replications matching the provided filter.

func (*Store) Lock

func (s *Store) Lock()

func (*Store) PopulateRemoteHTTPConfig

func (s *Store) PopulateRemoteHTTPConfig(ctx context.Context, id platform.ID, target *influxdb.ReplicationHTTPConfig) error

func (*Store) Unlock

func (s *Store) Unlock()

func (*Store) UpdateReplication

func (s *Store) UpdateReplication(ctx context.Context, id platform.ID, request influxdb.UpdateReplicationRequest) (*influxdb.Replication, error)

UpdateReplication updates a replication by ID. Caller is responsible for managing locks.

func (*Store) UpdateResponseInfo

func (s *Store) UpdateResponseInfo(ctx context.Context, id platform.ID, code int, message string) error

UpdateResponseInfo sets the most recent HTTP status code and error message received for a replication remote write.

Jump to

Keyboard shortcuts

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