Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConsumerConfig ¶
type ConsumerConfig struct { Enable bool `json:"enable" toml:"enable"` Addr []string `json:"addr" toml:"addr"` Topic string `json:"topic" toml:"topic"` Group string `json:"group" toml:"group"` DialTimeout time.Duration `json:"dialTimeout" toml:"dialTimeout"` RwTimeout time.Duration `json:"rwTimeout" toml:"rwTimeout"` SubExpression string `json:"subExpression" toml:"subExpression"` Rate float64 `json:"rate" toml:"rate"` Capacity int64 `json:"capacity" toml:"capacity"` WaitMaxDuration time.Duration `json:"waitMaxDuration" toml:"waitMaxDuration"` // contains filtered or unexported fields }
ConsumerConfig consumer config
func StdPushConsumerConfig ¶
func StdPushConsumerConfig(name string) ConsumerConfig
StdPushConsumerConfig ...
func (*ConsumerConfig) Build ¶
func (config *ConsumerConfig) Build() (rocketmq.PushConsumer, error)
Build ...
func (*ConsumerConfig) WithInterceptor ¶
func (config *ConsumerConfig) WithInterceptor(fs ...primitive.Interceptor) *ConsumerConfig
WithInterceptor ...
func (*ConsumerConfig) WithSubscribe ¶
func (config *ConsumerConfig) WithSubscribe(topic string, f func(context.Context, *primitive.MessageExt) error) *ConsumerConfig
WithSubscribe ...
type ProducerConfig ¶
type ProducerConfig struct { Addr []string `json:"addr" toml:"addr"` Topic string `json:"topic" toml:"topic"` Group string `json:"group" toml:"group"` Retry int `json:"retry" toml:"retry"` DialTimeout time.Duration `json:"dialTimeout" toml:"dialTimeout"` RwTimeout time.Duration `json:"rwTimeout" toml:"rwTimeout"` // contains filtered or unexported fields }
ProducerConfig producer config
func (ProducerConfig) Build ¶
func (config ProducerConfig) Build() (rocketmq.Producer, error)
Build ...
func (*ProducerConfig) WithInterceptor ¶
func (config *ProducerConfig) WithInterceptor(fs ...primitive.Interceptor) *ProducerConfig
WithInterceptor ...
Click to show internal directories.
Click to hide internal directories.