Documentation ¶
Index ¶
- func Start(cfw inter.Framework, handler http.Handler)
- type BuildInfo
- type ChoriaInfo
- type InstanceStatus
- func (i *InstanceStatus) CheckCertValidity(tillExpire time.Duration) error
- func (i *InstanceStatus) CheckConnection() error
- func (i *InstanceStatus) CheckFileAge(maxAge time.Duration) error
- func (i *InstanceStatus) CheckLastMessage(maxAge time.Duration) error
- func (i *InstanceStatus) CheckTokenValidity(tillExpire time.Duration) error
- type ServerStats
- type SysInfo
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type ChoriaInfo ¶ added in v0.19.0
type ChoriaInfo struct { Build BuildInfo `json:"build"` System SysInfo `json:"system"` ConfigFile string `json:"config_file"` Identity string `json:"identity"` }
func SystemInfo ¶ added in v0.19.0
func SystemInfo() ChoriaInfo
type InstanceStatus ¶ added in v0.19.0
type InstanceStatus struct { Identity string `json:"identity"` Uptime int64 `json:"uptime"` ConnectedServer string `json:"connected_server"` LastMessage int64 `json:"last_message"` Provisioning bool `json:"provisioning_mode"` Stats *ServerStats `json:"stats"` CertificateExpires time.Time `json:"certificate_expires"` TokenExpires time.Time `json:"token_expires"` FileName string `json:"-"` ModTime time.Time `json:"-"` }
InstanceStatus describes the current instance status
func LoadInstanceStatus ¶ added in v0.19.0
func LoadInstanceStatus(f string) (*InstanceStatus, error)
func (*InstanceStatus) CheckCertValidity ¶ added in v0.23.0
func (i *InstanceStatus) CheckCertValidity(tillExpire time.Duration) error
func (*InstanceStatus) CheckConnection ¶ added in v0.19.0
func (i *InstanceStatus) CheckConnection() error
CheckConnection checks if the server is currently connected
func (*InstanceStatus) CheckFileAge ¶ added in v0.19.0
func (i *InstanceStatus) CheckFileAge(maxAge time.Duration) error
func (*InstanceStatus) CheckLastMessage ¶ added in v0.19.0
func (i *InstanceStatus) CheckLastMessage(maxAge time.Duration) error
func (*InstanceStatus) CheckTokenValidity ¶ added in v0.25.0
func (i *InstanceStatus) CheckTokenValidity(tillExpire time.Duration) error
type ServerStats ¶ added in v0.19.0
type ServerStats struct { Total int64 `json:"total"` Valid int64 `json:"valid"` Invalid int64 `json:"invalid"` Passed int64 `json:"passed"` Filtered int64 `json:"filtered"` Replies int64 `json:"replies"` TTLExpired int64 `json:"ttlexpired"` Events int64 `json:"events"` }
ServerStats are internal statistics about the running server
Click to show internal directories.
Click to hide internal directories.