statussynccontroller

package
v2.7.3 Latest Latest
Warning

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

Go to latest
Published: Mar 26, 2024 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Overview

Package statussynccontroller implements the StatusSyncController.

Index

Constants

View Source
const (
	// Category is the category of StatusSyncController.
	Category = supervisor.CategorySystemController

	// Kind is the kind of StatusSyncController.
	Kind = "StatusSyncController"
)
View Source
const (
	// SyncStatusPaceInUnixSeconds must be 5s because the rates of http stat.
	// https://github.com/rcrowley/go-metrics/blob/3113b8401b8a98917cde58f8bbd42a1b1c03b1fd/ewma.go#L98-L99
	SyncStatusPaceInUnixSeconds = 5
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Spec

type Spec struct{}

Spec describes StatusSyncController.

type StatusSyncController

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

StatusSyncController is a system controller to synchronize status of every object to remote storage.

func (*StatusSyncController) Category

Category returns the category of StatusSyncController.

func (*StatusSyncController) Close

func (ssc *StatusSyncController) Close()

Close closes StatusSyncController.

func (*StatusSyncController) DefaultSpec

func (ssc *StatusSyncController) DefaultSpec() interface{}

DefaultSpec returns the default spec of StatusSyncController.

func (*StatusSyncController) GetStatusSnapshots

func (ssc *StatusSyncController) GetStatusSnapshots() []*StatusesSnapshot

GetStatusSnapshots return the latest status snapshots.

func (*StatusSyncController) Inherit

func (ssc *StatusSyncController) Inherit(spec *supervisor.Spec, previousGeneration supervisor.Object)

Inherit inherits previous generation of StatusSyncController.

func (*StatusSyncController) Init

func (ssc *StatusSyncController) Init(superSpec *supervisor.Spec)

Init initializes StatusSyncController.

func (*StatusSyncController) Kind

func (ssc *StatusSyncController) Kind() string

Kind return the kind of StatusSyncController.

func (*StatusSyncController) Status

func (ssc *StatusSyncController) Status() *supervisor.Status

Status returns the status of StatusSyncController.

type StatusesSnapshot

type StatusesSnapshot struct {
	Statuses      map[string]*supervisor.Status
	UnixTimestamp int64
}

StatusesSnapshot is the history record for status of every running object.

Jump to

Keyboard shortcuts

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