Documentation ¶
Index ¶
Constants ¶
View Source
const (
SchemaName = "chs-delta"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type KafkaService ¶
type KafkaService interface { Init(cfg *config.Config) error SendMessage(topic, data, contextId string, isDelete bool) error }
KafkaService defines all Methods needed to successfully send a message onto a Kafka topic.
type KafkaServiceImpl ¶
KafkaServiceImpl is a concrete implementation of the KafkaService interface.
func NewKafkaService ¶
func NewKafkaService() KafkaServiceImpl
NewKafkaService returns a KafkaServiceImpl that isn't configured.
func (*KafkaServiceImpl) Init ¶
func (kSvc *KafkaServiceImpl) Init(cfg *config.Config) error
Init initialises a KafkaService using a provided config.
func (*KafkaServiceImpl) SendMessage ¶
func (kSvc *KafkaServiceImpl) SendMessage(topic, data, contextId string, isDelete bool) error
SendMessage publishes a given data string retrieved from a REST request onto a chosen Kafka topic.
Click to show internal directories.
Click to hide internal directories.