You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

23 lines
414 B
Go

package producer
import (
"context"
"joybuywork/internal/service/queue/types"
)
type StatCampaign struct {
ctx context.Context
topic string
}
func NewStatCampaign(ctx context.Context) StatCampaign {
return StatCampaign{
ctx: ctx,
topic: types.StatCampaignTopic,
}
}
func (p StatCampaign) StatCampaign(data types.StatCampaignValue) {
_ = AP.Produce(p.ctx, p.topic, types.StatCampaignKey, data)
}