Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DataRecorder ¶
type DataRecorder interface { // Reader should not block when RecordJob is sent to this channel. PayloadChan() chan *RecordJob // The recorder's loop should be inside a goroutine, and return a channel. // This channel should be closed one it's work is finished and wants to quit. Start() chan struct{} Name() string }
DataRecorder in an interface for shipping data to a repository. The repository should have the concept of index/database and type/table abstractions. See ElasticSearch for more information. Recorder should send nil to Err channel if no error occurs.
type MockRecorder ¶
type MockRecorder struct { PayloadChanFunc func() chan *RecordJob ErrorFunc func() error StartFunc func() chan struct{} }
func (*MockRecorder) Error ¶
func (m *MockRecorder) Error() error
func (*MockRecorder) PayloadChan ¶
func (m *MockRecorder) PayloadChan() chan *RecordJob
func (*MockRecorder) Start ¶
func (m *MockRecorder) Start() chan struct{}
type RecordJob ¶
type RecordJob struct { Ctx context.Context Payload datatype.DataContainer IndexName string TypeName string Time time.Time // Is used for timeseries data Err chan error }
RecordJob is sent with a context and a payload to be recorded If the TypeName and IndexName are different than the previous one, the recorder should use the new ones
Click to show internal directories.
Click to hide internal directories.