Documentation ¶
Overview ¶
Package stats provides functionality for basic usage statistics in Goophry.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Stats ¶
type Stats struct {
// contains filtered or unexported fields
}
Stats provides routines to gather basic statistics and serve them through a HTTP-server.
func (*Stats) IncrTaskCount ¶
IncrTaskCount increments the counter of a certain task.
func (*Stats) InitTask ¶
InitTask initialises the task-counter for a certain task. The counter should be initialised so that it will be returned in the HTTP response, even when it is 0.
func (Stats) ServeHttp ¶
ServeHttp spawns an HTTP-server, that responds with a statsResponse in JSON.
func (Stats) ServeHttps ¶
ServeHttps spawns an HTTP-server, that responds with a statsResponse in JSON, expecting HTTPS connections.
func (*Stats) SetVersion ¶
SetVersion updates the version-number of the Goophry application.