Documentation ¶
Overview ¶
Package memory provides an in-memory volatile config store implementation
Index ¶
Constants ¶
View Source
const (
// BufferSize specifies the buffer size of event channel
BufferSize = 100
)
Variables ¶
This section is empty.
Functions ¶
func Make ¶
func Make(descriptor model.ConfigDescriptor) model.ConfigStore
Make creates an in-memory config store from a config descriptor
func NewController ¶
func NewController(cs model.ConfigStore) model.ConfigStoreCache
NewController return an implementation of model.ConfigStoreCache This is a client-side monitor that dispatches events as the changes are being made on the client.
Types ¶
type ConfigEvent ¶
type ConfigEvent struct {
// contains filtered or unexported fields
}
ConfigEvent defines the event to be processed
type Monitor ¶
type Monitor interface { Run(<-chan struct{}) AppendEventHandler(string, Handler) ScheduleProcessEvent(ConfigEvent) }
Monitor provides methods of manipulating changes in the config store
func NewBufferedMonitor ¶
func NewBufferedMonitor(store model.ConfigStore, bufferSize int) Monitor
NewBufferedMonitor returns new Monitor implementation with the specified event buffer size
func NewMonitor ¶
func NewMonitor(store model.ConfigStore) Monitor
NewMonitor returns new Monitor implementation with a default event buffer size.
Click to show internal directories.
Click to hide internal directories.