Documentation ¶
Index ¶
- func GetHealth() metric.HealthMeta
- func SetUnhealthy(key string, message interface{})
- type APIResource
- func (a *APIResource) GetDBClient(key string) drivers.DB
- func (a *APIResource) GetEventBus(key string) *watchbus.EventBus
- func (a *APIResource) GetMsgQueue() *MessageQueue
- func (a *APIResource) GetStoreClient(key string) store.Store
- func (a *APIResource) InitActions()
- func (a *APIResource) ParseDBConfig() *conf.Config
- func (a *APIResource) ParseQueueConfig() *conf.Config
- func (a *APIResource) SetConfig(op *options.StorageOptions)
- type BcsHealthIf
- type MessageQueue
- type SubStatus
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SetUnhealthy ¶
func SetUnhealthy(key string, message interface{})
SetUnhealthy set storage to unhealthy status
Types ¶
type APIResource ¶
type APIResource struct { Conf *options.StorageOptions ActionsV1 []*httpserver.Action // contains filtered or unexported fields }
APIResource api resource object
func GetAPIResource ¶
func GetAPIResource() *APIResource
GetAPIResource that loads config from config-file and handlers from api-actions
func (*APIResource) GetDBClient ¶
func (a *APIResource) GetDBClient(key string) drivers.DB
GetDBClient get db client by key
func (*APIResource) GetEventBus ¶
func (a *APIResource) GetEventBus(key string) *watchbus.EventBus
GetEventBus get event bus by key
func (*APIResource) GetMsgQueue ¶ added in v0.20.3
func (a *APIResource) GetMsgQueue() *MessageQueue
GetMsgQueue get queue client
func (*APIResource) GetStoreClient ¶
func (a *APIResource) GetStoreClient(key string) store.Store
GetStoreClient get store client by keys
func (*APIResource) ParseDBConfig ¶
func (a *APIResource) ParseDBConfig() *conf.Config
ParseDBConfig parse db config
func (*APIResource) ParseQueueConfig ¶ added in v0.20.3
func (a *APIResource) ParseQueueConfig() *conf.Config
ParseQueueConfig parse queue config
func (*APIResource) SetConfig ¶
func (a *APIResource) SetConfig(op *options.StorageOptions)
SetConfig Set storageConfig to APIResource
type BcsHealthIf ¶
type BcsHealthIf struct { Code int `json:"code"` OK bool `json:"ok"` Data healthStatus `json:"data"` Message string `json:"message"` }
BcsHealthIf interface
type MessageQueue ¶ added in v0.20.3
type MessageQueue struct { QueueFlag bool MsgQueue msgqueue.MessageQueue }
MessageQueue queue object
Click to show internal directories.
Click to hide internal directories.