Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MemoryStore ¶
type MemoryStore struct { TTL time.Duration Logger *zap.Logger Results map[string]*healthcheck.Result Tick *time.Ticker // contains filtered or unexported fields }
MemoryStore A store containing the latest healthchecks results
func NewMemoryStore ¶
func NewMemoryStore(logger *zap.Logger) *MemoryStore
NewMemoryStore creates a new memory store
func (*MemoryStore) Add ¶
func (m *MemoryStore) Add(result *healthcheck.Result)
Add a new Result to the store
func (*MemoryStore) Get ¶
func (m *MemoryStore) Get(name string) (healthcheck.Result, error)
Get returns the current value for a healthcheck
func (*MemoryStore) List ¶
func (m *MemoryStore) List() []healthcheck.Result
List returns the current value of the results
Click to show internal directories.
Click to hide internal directories.