state

package
v0.2.6 Latest Latest
Warning

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

Go to latest
Published: Apr 23, 2023 License: Apache-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	RequestPath  = "/state/request"
	RequestsPath = "/state/requests"
)

Variables

View Source
var (
	DatabaseCfgPath = "/state/metadata/local/database/config"
)
View Source
var (
	ExplorePath = "/state/machine/explore"
)
View Source
var (
	MemoryDatabase = "/state/tsdb/memory"
)
View Source
var (
	ReplicaPath = "/state/replica"
)

Functions

This section is empty.

Types

type MetadataAPI added in v0.1.1

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

MetadataAPI represents internal metadata state rest api.

func NewMetadataAPI added in v0.1.1

func NewMetadataAPI(engine tsdb.Engine) *MetadataAPI

NewMetadataAPI creates a metadata api instance.

func (*MetadataAPI) GetLocalAllDatabaseCfg added in v0.1.1

func (m *MetadataAPI) GetLocalAllDatabaseCfg(c *gin.Context)

GetLocalAllDatabaseCfg returns the configuration map of all local databases.

func (*MetadataAPI) Register added in v0.1.1

func (m *MetadataAPI) Register(route gin.IRoutes)

Register adds metadata api url route.

type ReplicaAPI

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

ReplicaAPI represents internal replica state rest api.

func NewReplicaAPI

func NewReplicaAPI(walMgr replica.WriteAheadLogManager) *ReplicaAPI

NewReplicaAPI creates a replica state api instance.

func (*ReplicaAPI) GetReplicaState

func (d *ReplicaAPI) GetReplicaState(c *gin.Context)

GetReplicaState returns replica state by given database's name.

func (*ReplicaAPI) Register

func (d *ReplicaAPI) Register(route gin.IRoutes)

Register adds explore url route.

type RequestAPI

type RequestAPI struct {
}

RequestAPI represents lin query request stats related api.

func NewRequestAPI

func NewRequestAPI() *RequestAPI

NewRequestAPI creates a RequestAPI instance.

func (*RequestAPI) GetAllAliveRequests

func (r *RequestAPI) GetAllAliveRequests(c *gin.Context)

GetAllAliveRequests returns all alive requests.

func (*RequestAPI) GetRequestState

func (r *RequestAPI) GetRequestState(c *gin.Context)

GetRequestState returns request stats by given request id.

func (*RequestAPI) Register

func (r *RequestAPI) Register(route gin.IRoutes)

Register adds request api route.

type StorageStateMachineAPI

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

func NewStorageStateMachineAPI

func NewStorageStateMachineAPI(stateMgr storage.StateManager) *StorageStateMachineAPI

NewStorageStateMachineAPI creates storage state machine api instance.

func (*StorageStateMachineAPI) Explore

func (api *StorageStateMachineAPI) Explore(c *gin.Context)

Explore explores the state from storage state machine.

func (*StorageStateMachineAPI) Register

func (api *StorageStateMachineAPI) Register(route gin.IRoutes)

Register adds state machine url route.

type TSDBAPI

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

TSDBAPI represents tsdb internal state rest api.

func NewTSDBAPI

func NewTSDBAPI() *TSDBAPI

NewTSDBAPI creates a tsdb state api instance.

func (*TSDBAPI) GetMemoryDatabaseState

func (db *TSDBAPI) GetMemoryDatabaseState(c *gin.Context)

GetMemoryDatabaseState returns memory database

func (*TSDBAPI) Register

func (db *TSDBAPI) Register(route gin.IRoutes)

Register adds the route for tsdb state api.

Jump to

Keyboard shortcuts

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