server

package
v1.6.2 Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2022 License: MIT Imports: 27 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// APITimeFormat - clickhouse compatibility time format
	APITimeFormat  = "2006-01-02 15:04:05"
	InProgressText = "in progress"
)

Variables

View Source
var (
	ErrAPILocked = errors.New("another operation is currently running")
)

Functions

func Server

func Server(c *cli.App, configPath string, clickhouseBackupVersion string) error

Server - expose CLI commands as REST API

Types

type APIServer

type APIServer struct {
	// contains filtered or unexported fields
}

func (*APIServer) CreateIntegrationTables added in v1.0.0

func (api *APIServer) CreateIntegrationTables() error

func (*APIServer) Restart added in v0.6.3

func (api *APIServer) Restart() error

type ActionRow added in v0.6.2

type ActionRow struct {
	Command string `json:"command"`
	Status  string `json:"status"`
	Start   string `json:"start,omitempty"`
	Finish  string `json:"finish,omitempty"`
	Error   string `json:"error,omitempty"`
}

type AsyncStatus

type AsyncStatus struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

type Metrics

type Metrics struct {
	SuccessfulCounter map[string]prometheus.Counter
	FailedCounter     map[string]prometheus.Counter
	LastStart         map[string]prometheus.Gauge
	LastFinish        map[string]prometheus.Gauge
	LastDuration      map[string]prometheus.Gauge
	LastStatus        map[string]prometheus.Gauge

	LastBackupSizeLocal         prometheus.Gauge
	LastBackupSizeRemote        prometheus.Gauge
	NumberBackupsRemote         prometheus.Gauge
	NumberBackupsLocal          prometheus.Gauge
	NumberBackupsRemoteExpected prometheus.Gauge
	NumberBackupsLocalExpected  prometheus.Gauge
}

Jump to

Keyboard shortcuts

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