Documentation ¶
Index ¶
- func Client() *client
- func Consumer() iConsumer
- func GetClient(names ...string) *client
- func Init(configs ...Config) (err error)
- func New(conf Config) (*client, error)
- func Producer() iProducer
- type Config
- type ConsumerError
- type ConsumerHandler
- type ConsumerMessage
- type MessageHandler
- type ProducerMessage
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct { User string `json:"user,optional" yaml:"User"` Name string `json:"name,optional" yaml:"Name"` Password string `json:"password,optional" yaml:"Password"` Addrs []string `json:"addrs,optional" yaml:"Addrs"` Timeout int `json:"timeout,optional" yaml:"Timeout"` HeartbeatInterval int `json:"heartbeatInterval" yaml:"HeartbeatInterval"` SessionTimeout int `json:"sessionTimeout" yaml:"SessionTimeout"` RebalanceTimeout int `json:"rebalanceTimeout" yaml:"RebalanceTimeout"` OffsetNewest bool `json:"offsetNewest" yaml:"OffsetNewest"` }
type ConsumerError ¶
type ConsumerError struct {
*sarama.ConsumerError
}
type ConsumerHandler ¶
type ConsumerHandler func(msg *ConsumerMessage, consumerErr *ConsumerError) error
type ConsumerMessage ¶
type ConsumerMessage struct {
*sarama.ConsumerMessage
}
type MessageHandler ¶
type MessageHandler func(msg *ProducerMessage, err error)
type ProducerMessage ¶
type ProducerMessage struct {
*sarama.ProducerMessage
}
Source Files ¶
Click to show internal directories.
Click to hide internal directories.