icarus

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: Jun 21, 2026 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	StatePending   = "PENDING"
	StateRunning   = "RUNNING"
	StateCompleted = "COMPLETED"
	StateCancelled = "CANCELLED"
	StateFailed    = "FAILED"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Backup

type Backup struct {
	ID                     string    `json:"id"`
	CreationTime           string    `json:"creationTime"`
	State                  string    `json:"state"`
	Errors                 []Error   `json:"errors"`
	Progress               float64   `json:"progress"`
	StartTime              string    `json:"startTime"`
	Type                   string    `json:"type"`
	StorageLocation        string    `json:"storageLocation"`
	ConcurrentConnections  int64     `json:"concurrentConnections"`
	MetadataDirective      string    `json:"metadataDirective"`
	Entities               string    `json:"entities"`
	SnapshotTag            string    `json:"snapshotTag"`
	GlobalRequest          bool      `json:"globalRequest"`
	Timeout                int64     `json:"timeout"`
	Insecure               bool      `json:"insecure"`
	SchemaVersion          string    `json:"schemaVersion"`
	CreateMissingBucket    bool      `json:"createMissingBucket"`
	SkipBucketVerification bool      `json:"skipBucketVerification"`
	UploadClusterTopology  bool      `json:"uploadClusterTopology"`
	Retry                  Retry     `json:"retry"`
	SkipRefreshing         bool      `json:"skipRefreshing"`
	DataDirs               []string  `json:"dataDirs"`
	DC                     string    `json:"dc"`
	K8sNamespace           string    `json:"k8sNamespace"`
	K8sSecretName          string    `json:"k8sSecretName"`
	Duration               string    `json:"duration"`
	Bandwidth              *DataRate `json:"bandwidth"`
}

type BackupRequest

type BackupRequest struct {
	Type                   string    `json:"type"`
	StorageLocation        string    `json:"storageLocation"`
	DataDirs               []string  `json:"dataDirs"`
	GlobalRequest          bool      `json:"globalRequest"`
	SnapshotTag            string    `json:"snapshotTag"`
	K8sNamespace           string    `json:"k8sNamespace,omitempty"`
	K8sSecretName          string    `json:"k8sSecretName,omitempty"`
	Duration               string    `json:"duration,omitempty"`
	Bandwidth              *DataRate `json:"bandwidth,omitempty"`
	ConcurrentConnections  int64     `json:"concurrentConnections,omitempty"`
	DC                     string    `json:"dc,omitempty"`
	Entities               string    `json:"entities,omitempty"`
	Timeout                int64     `json:"timeout,omitempty"`
	MetadataDirective      string    `json:"metadataDirective,omitempty"`
	Insecure               bool      `json:"insecure"`
	CreateMissingBucket    bool      `json:"createMissingBucket"`
	SkipRefreshing         bool      `json:"skipRefreshing"`
	SkipBucketVerification bool      `json:"skipBucketVerification"`
	Retry                  Retry     `json:"retry,omitempty"`
}

type DataRate

type DataRate struct {
	Value int64  `json:"value"`
	Unit  string `json:"unit"`
}

type Error

type Error struct {
	Source  string `json:"source"`
	Message string `json:"message"`
}

type Icarus

type Icarus interface {
	Backup(ctx context.Context, req BackupRequest) (Backup, error)
	Backups(ctx context.Context) ([]Backup, error)
	Restore(ctx context.Context, req RestoreRequest) error
	Restores(ctx context.Context) ([]Restore, error)
}

func New

func New(addr string) Icarus

type Restore

type Restore struct {
	Id                        string            `json:"id"`
	CreationTime              string            `json:"creationTime"`
	State                     string            `json:"state"`
	Errors                    []Error           `json:"errors"`
	Progress                  float64           `json:"progress"`
	StartTime                 string            `json:"startTime"`
	Type                      string            `json:"type"`
	StorageLocation           string            `json:"storageLocation"`
	ConcurrentConnections     int64             `json:"concurrentConnections"`
	CassandraConfigDirectory  string            `json:"cassandraConfigDirectory"`
	RestoreSystemKeyspace     bool              `json:"restoreSystemKeyspace"`
	SnapshotTag               string            `json:"snapshotTag"`
	Entities                  string            `json:"entities"`
	RestorationStrategyType   string            `json:"restorationStrategyType"`
	RestorationPhase          string            `json:"restorationPhase"`
	Import                    RestoreImport     `json:"import"`
	NoDeleteTruncates         bool              `json:"noDeleteTruncates"`
	NoDeleteDownloads         bool              `json:"noDeleteDownloads"`
	NoDownloadData            bool              `json:"noDownloadData"`
	ExactSchemaVersion        bool              `json:"exactSchemaVersion"`
	GlobalRequest             bool              `json:"globalRequest"`
	Timeout                   int64             `json:"timeout"`
	ResolveHostIdFromTopology bool              `json:"resolveHostIdFromTopology"`
	Insecure                  bool              `json:"insecure"`
	SkipBucketVerification    bool              `json:"skipBucketVerification"`
	Retry                     Retry             `json:"retry"`
	SinglePhase               bool              `json:"singlePhase"`
	DataDirs                  []string          `json:"dataDirs"`
	DC                        string            `json:"dc"`
	K8sNamespace              string            `json:"k8sNamespace"`
	K8sSecretName             string            `json:"k8sSecretName"`
	Rename                    map[string]string `json:"rename"`
}

type RestoreImport

type RestoreImport struct {
	Type               string `json:"type"`
	SourceDir          string `json:"sourceDir"`
	KeepLevel          bool   `json:"keepLevel,omitempty"`
	NoVerify           bool   `json:"noVerify,omitempty"`
	NoVerifyTokens     bool   `json:"noVerifyTokens,omitempty"`
	NoInvalidateCaches bool   `json:"noInvalidateCaches,omitempty"`
	Quick              bool   `json:"quick,omitempty"`
	ExtendedVerify     bool   `json:"extendedVerify,omitempty"`
	KeepRepaired       bool   `json:"keepRepaired,omitempty"`
}

type RestoreRequest

type RestoreRequest struct {
	Type                      string            `json:"type"`
	StorageLocation           string            `json:"storageLocation"`
	SnapshotTag               string            `json:"snapshotTag"`
	DataDirs                  []string          `json:"dataDirs"`
	GlobalRequest             bool              `json:"globalRequest"`
	RestorationStrategyType   string            `json:"restorationStrategyType"`
	RestorationPhase          string            `json:"restorationPhase"`
	Import                    RestoreImport     `json:"import"`
	K8sNamespace              string            `json:"k8sNamespace,omitempty"`
	K8sSecretName             string            `json:"k8sSecretName,omitempty"`
	ConcurrentConnections     int64             `json:"concurrentConnections,omitempty"`
	Entities                  string            `json:"entities,omitempty"`
	NoDeleteTruncates         bool              `json:"noDeleteTruncates,omitempty"`
	NoDeleteDownloads         bool              `json:"noDeleteDownloads,omitempty"`
	NoDownloadData            bool              `json:"noDownloadData,omitempty"`
	Timeout                   int64             `json:"timeout,omitempty"`
	ResolveHostIdFromTopology bool              `json:"resolveHostIdFromTopology,omitempty"`
	Insecure                  bool              `json:"insecure,omitempty"`
	SkipBucketVerification    bool              `json:"skipBucketVerification,omitempty"`
	Retry                     Retry             `json:"retry,omitempty"`
	Rename                    map[string]string `json:"rename,omitempty"`
	SinglePhase               bool              `json:"singlePhase,omitempty"`
	DC                        string            `json:"dc,omitempty"`
	SchemaVersion             string            `json:"schemaVersion,omitempty"`
	ExactSchemaVersion        bool              `json:"exactSchemaVersion,omitempty"`
}

type Retry

type Retry struct {
	Interval    int64  `json:"interval"`
	Strategy    string `json:"strategy"`
	MaxAttempts int64  `json:"maxAttempts"`
	Enabled     bool   `json:"enabled"`
}

Jump to

Keyboard shortcuts

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