models

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Dec 23, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AwsS3

type AwsS3 struct {
	BucketName string
	Region     string
	Profile    string
	Endpoint   string
}

func (*AwsS3) LoadSecrets

func (a *AwsS3) LoadSecrets(cfg *backup.SecretAgentConfig) error

LoadSecrets tries to load field values from secret agent.

type AzureBlob

type AzureBlob struct {
	// Account name + key auth
	AccountName string
	AccountKey  string
	// Azure Active directory
	TenantID     string
	ClientID     string
	ClientSecret string

	Endpoint      string
	ContainerName string
}

func (*AzureBlob) LoadSecrets

func (a *AzureBlob) LoadSecrets(cfg *backup.SecretAgentConfig) error

LoadSecrets tries to load field values from secret agent.

type Backup

type Backup struct {
	OutputFile          string
	RemoveFiles         bool
	ModifiedBefore      string
	ModifiedAfter       string
	FileLimit           int64
	AfterDigest         string
	MaxRecords          int64
	NoBins              bool
	SleepBetweenRetries int
	FilterExpression    string
	ParallelNodes       bool
	RemoveArtifacts     bool
	Compact             bool
	NodeList            string
	NoTTLOnly           bool
	PreferRacks         string
	PartitionList       string
	Estimate            bool
	EstimateSamples     int64
	StateFileDst        string
	Continue            string
	ScanPageSize        int64
	OutputFilePrefix    string
}

func (*Backup) ShouldClearTarget

func (b *Backup) ShouldClearTarget() bool

ShouldClearTarget check if we should clean target directory.

func (*Backup) ShouldSaveState

func (b *Backup) ShouldSaveState() bool

type ClientPolicy

type ClientPolicy struct {
	Timeout      int64
	IdleTimeout  int64
	LoginTimeout int64
}

type Common

type Common struct {
	Directory        string
	Namespace        string
	SetList          string
	BinList          string
	Parallel         int
	NoRecords        bool
	NoIndexes        bool
	NoUDFs           bool
	RecordsPerSecond int
	MaxRetries       int
	TotalTimeout     int64
	SocketTimeout    int64

	// Nice is mapped to config.Bandwidth
	// Is set in MiB then converted to bytes.
	Nice int
}

Common parameters are used by both backup and restore operations.

type Compression

type Compression struct {
	Mode  string
	Level int
}

type Encryption

type Encryption struct {
	Mode      string
	KeyFile   string
	KeyEnv    string
	KeySecret string
}

type GcpStorage

type GcpStorage struct {
	// Path to file containing Service Account JSON Key.
	KeyFile string
	// For GPC storage bucket is not part of the path as in S3.
	// So we should set it separately.
	BucketName string
	// Alternative url.
	// It is not recommended to use an alternate URL in a production environment.
	Endpoint string
}

func (*GcpStorage) LoadSecrets

func (g *GcpStorage) LoadSecrets(cfg *backup.SecretAgentConfig) error

LoadSecrets tries to load field values from secret agent.

type Restore

type Restore struct {
	InputFile          string
	DirectoryList      string
	ParentDirectory    string
	DisableBatchWrites bool
	BatchSize          int
	MaxAsyncBatches    int
	ExtraTTL           int64
	IgnoreRecordError  bool
	Uniq               bool
	Replace            bool
	NoGeneration       bool
	TimeOut            int64

	RetryBaseTimeout int64
	RetryMultiplier  float64
	RetryMaxRetries  uint
}

type SecretAgent

type SecretAgent struct {
	ConnectionType     string
	Address            string
	Port               int
	TimeoutMillisecond int
	CaFile             string
	IsBase64           bool
}

Jump to

Keyboard shortcuts

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