Documentation ¶
Index ¶
Constants ¶
View Source
const ( // Suffix is a suffix added to the backup while it's in-process. Suffix = ".pending" // Metafile is the base name given to the metastore backups. Metafile = "meta" // BackupFilePattern is the beginning of the pattern for a backup // file. They follow the scheme <database>.<retention>.<shardID>.<increment> BackupFilePattern = "%s.%s.%05d" PortableFileNamePattern = "20060102T150405Z" )
Variables ¶
This section is empty.
Functions ¶
func DBRetentionAndShardFromPath ¶
retentionAndShardFromPath will take the shard relative path and split it into the retention policy name and shard ID. The first part of the path should be the database name.
func GetMetaBytes ¶
Types ¶
type CountingWriter ¶
type Entry ¶
type Entry struct { Database string `json:"database"` Policy string `json:"policy"` ShardID uint64 `json:"shardID"` FileName string `json:"fileName"` Size int64 `json:"size"` LastModified int64 `json:"lastModified"` }
Entry contains the data information for a backed up shard.
func (*Entry) SizeOrZero ¶
type Manifest ¶
type Manifest struct { Meta MetaEntry `json:"meta"` Limited bool `json:"limited"` Files []Entry `json:"files"` Database string `json:"database,omitempty"` Policy string `json:"policy,omitempty"` ShardID uint64 `json:"shard_id,omitempty"` }
Manifest lists the meta and shard file information contained in the backup. If Limited is false, the manifest contains a full backup, otherwise it is a partial backup.
type PortablePacker ¶
func (PortablePacker) MarshalBinary ¶
func (ep PortablePacker) MarshalBinary() ([]byte, error)
func (*PortablePacker) UnmarshalBinary ¶
func (ep *PortablePacker) UnmarshalBinary(data []byte) error
Click to show internal directories.
Click to hide internal directories.