Documentation ¶
Index ¶
Constants ¶
View Source
const ( AVS_STATUS_DOWN = 0 AVS_STATUS_UP = 1 )
Variables ¶
This section is empty.
Functions ¶
func AddControllerToManager ¶
func AddControllerToManager(logger logging.Logger, mgr manager.Manager, config *config.LandscaperServiceConfiguration) error
AddControllerToManager adds the AVUploader controller to the manager
func NewController ¶
Types ¶
type AvsInstance ¶
type AvsInstance struct { // InstanceId is the id of the monitored instance. InstanceId string `json:"instanceId"` // Name is a name for the instance. Name string `json:"name"` // OutageReason is the reason this instance is unavailable. OutageReason string `json:"outageReason"` // Status is the availability status for the instance: 0 = DOWN, 1 = UP. Status int `json:"status"` }
AvsInstance is a status of a single monitored instance.
type AvsRequest ¶
type AvsRequest struct { // Timestamp is the timestamp the data was collected. Must be newer than the one in the last request. Timestamp int64 `json:"timestamp"` // Response time is the time the availability check took. ResponseTime int `json:"responseTime"` // ResponseStatusCode is the http response code received from the service that is av monitored. ResponseStatusCode int `json:"responseStatusCode"` // OutageReason is the reason the av monitored service is unavailable. OutageReason string `json:"outageReason"` // Status is the availability status for the service: 0 = DOWN, 1 = UP. Status int `json:"status"` // Instances allow to give an av status for multiple instances. If one of the instances is DOWN, the overall status is DOWN. Instances []AvsInstance `json:"instances"` }
AvsRequest contains the structure for a request to avs to push availability information.
type Controller ¶
func NewTestActuator ¶
func NewTestActuator(op operation.Operation, logger logging.Logger) *Controller
NewTestActuator creates a new controller for testing purposes.
Click to show internal directories.
Click to hide internal directories.