Documentation ¶
Index ¶
- type Consumer
- type Environment
- type MockConsumer
- func (mc *MockConsumer) Close() (err error)
- func (mc *MockConsumer) Commit() ([]kafka.TopicPartition, error)
- func (mc *MockConsumer) CreateEvent(ev kafka.Event)
- func (mc *MockConsumer) CreateMessage()
- func (mc *MockConsumer) Events() chan kafka.Event
- func (mc *MockConsumer) Poll(timeoutMs int) kafka.Event
- type MockEvent
- type Reader
- type Writer
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Consumer ¶
type Consumer interface { Poll(int) kafka.Event Commit() ([]kafka.TopicPartition, error) Close() (err error) }
Consumer interface
type Environment ¶
Environment represents the current inspr environment
func GetKafkaEnvironment ¶
func GetKafkaEnvironment() *Environment
GetKafkaEnvironment returns the current inspr environment
func RefreshEnviromentVariables ¶
func RefreshEnviromentVariables() *Environment
RefreshEnviromentVariables "refreshes" the value of kafka environment variables. This was develop for testing and probably sholdn't be used in other cases.
type MockConsumer ¶
type MockConsumer struct {
// contains filtered or unexported fields
}
MockConsumer mock
func (*MockConsumer) Commit ¶
func (mc *MockConsumer) Commit() ([]kafka.TopicPartition, error)
Commit mock
func (*MockConsumer) CreateEvent ¶
func (mc *MockConsumer) CreateEvent(ev kafka.Event)
CreateEvent creates an event on the mock channel of thre consumer
func (*MockConsumer) CreateMessage ¶
func (mc *MockConsumer) CreateMessage()
CreateMessage creates a message on the mock consumer from the field defined in the structure
func (*MockConsumer) Events ¶
func (mc *MockConsumer) Events() chan kafka.Event
Events mock for the events channel
type Reader ¶
type Reader struct {
// contains filtered or unexported fields
}
Reader reads/commit messages from the channels defined in the env
Click to show internal directories.
Click to hide internal directories.