Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewSecureServer ¶
NewSecureServer creates a new Secure HTTP Server (TLS).
func QueryHTTPMetric ¶
Types ¶
type Config ¶
type Config struct { Env string `json:"env"` TLSEnable bool `json:"tlsEnable"` TLSCRT string `json:"tlsCRT"` TLSKey string `json:"tlsKey"` Port int `json:"port"` LogFile string `json:"logFile"` Name string `json:"name"` MetricsRouter ConfigMetricsRouter `json:"metricsRouter"` Metrics []ConfigMetric `json:"metrics"` }
func NewConfigUsing ¶
func NewDevelopmentConfig ¶
func (*Config) LogSummary ¶
func (c *Config) LogSummary()
func (*Config) ReadProperty ¶
ReadProperty lets properties be read from the config using a query path (e.g. "metrics.0.name"). If any errors occur, we return an empty string.
type ConfigMetric ¶
type ConfigMetric struct { Enabled bool `json:"enabled"` Type string `json:"type"` // e.g. "build-number", "http" Name string `json:"name"` Method string `json:"method"` URL string `json:"url"` Data map[string]string `json:"data"` Headers map[string]string `json:"headers"` Periodicity Duration `json:"periodicity"` // Need to use our Duration so we can unmarshal Timeout Duration `json:"timeout"` StringToCheck string `json:"stringToCheck"` }
type ConfigMetricsRouter ¶
Click to show internal directories.
Click to hide internal directories.