Documentation ¶
Overview ¶
Package snapshotter provides the meta snapshot service.
Index ¶
Constants ¶
View Source
const ( // MuxHeader is the header byte used for the TCP muxer. MuxHeader = 3 // BackupMagicHeader is the first 8 bytes used to identify and validate // a metastore backup file BackupMagicHeader = 0x59590101 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client provides an API for the snapshotter service.
type Request ¶
type Request struct { Type RequestType Database string RetentionPolicy string ShardID uint64 Since time.Time }
Request represents a request for a specific backup or for information about the shards on this server for a database or retention policy.
type RequestType ¶
type RequestType uint8
RequestType indicates the typeof snapshot request.
const ( // RequestShardBackup represents a request for a shard backup. RequestShardBackup RequestType = iota // RequestMetastoreBackup represents a request to back up the metastore. RequestMetastoreBackup // RequestDatabaseInfo represents a request for database info. RequestDatabaseInfo // RequestRetentionPolicyInfo represents a request for retention policy info. RequestRetentionPolicyInfo )
type Response ¶
type Response struct {
Paths []string
}
Response contains the relative paths for all the shards on this server that are in the requested database or retention policy.
type Service ¶
type Service struct { Node *influxdb.Node MetaClient interface { encoding.BinaryMarshaler Database(name string) *meta.DatabaseInfo } TSDBStore *tsdb.Store Listener net.Listener Logger zap.Logger // contains filtered or unexported fields }
Service manages the listener for the snapshot endpoint.
func (*Service) WithLogger ¶
WithLogger sets the logger on the service.
Click to show internal directories.
Click to hide internal directories.