package
25.1.0+incompatible
Repository: https://github.com/cockroachdb/cockroach.git
Documentation: pkg.go.dev
# Functions
CheckForLatestFileInCollection checks whether the directory pointed by store contains the latestFileName pointer directory.
CollectionsAndSubdir breaks up the given paths into those components, if applicable.
FindLatestFile returns a ioctx.ReaderCloserCtx of the most recent LATEST file.
FindPriorBackups finds "appended" incremental backups by searching for the subdirectories matching the naming pattern (e.g.
GetURIsByLocalityKV takes a slice of URIs for a single (possibly partitioned) backup, and returns the default backup destination URI and a map of all other URIs by locality KV, appending appendPath to the path component of both the default URI and all the locality URIs.
ListFullBackupsInCollection lists full backup paths in the collection of an export store.
MakeBackupDestinationStores makes ExternalStorage handles to the passed in destinationDirs, and returns a cleanup function that closes this stores.
ReadLatestFile reads the LATEST file from collectionURI and returns the path stored in the file.
ResolveBackupManifests resolves the URIs that point to the incremental layers (each of which can be partitioned) of backups into the actual backup manifests and metadata required to RESTORE.
ResolveDest resolves the true destination of a backup.
ResolveIncrementalsBackupLocation returns the resolved locations of incremental backups by looking into either the explicitly provided incremental backup collections, or the full backup collections if no explicit incremental collections are provided.
WriteNewLatestFile writes a new LATEST file to both the base directory and latest-history directory, depending on cluster version.
# Constants
DefaultLocalityValue is the default locality tag used in a locality aware backup/restore when an explicit COCKROACH_LOCALITY is not specified.
OmitManifest is a named const that can be passed to FindPriorBackups.
# Structs
ResolvedDestination encapsulates information that is populated while resolving the destination of a backup.