package producer import ( "context" "joybuywork/internal/service/queue/types" ) type DeepworkNotify struct { ctx context.Context topic string } func NewDeepworkNotify(ctx context.Context) DeepworkNotify { return DeepworkNotify{ ctx: ctx, topic: types.DeepworkNotifyTopic, } } func (p DeepworkNotify) CampaignStart(data types.DnCampaignStart) { _ = AP.Produce(p.ctx, p.topic, types.DnCampaignStartKey, data) } func (p DeepworkNotify) CampaignEnd(data types.DnCampaignEnd) { _ = AP.Produce(p.ctx, p.topic, types.DnCampaignEndKey, data) } func (p DeepworkNotify) RewardPushStatus(data types.DnRewardPushStatus) { _ = AP.Produce(p.ctx, p.topic, types.DnRewardPushStatusKey, data) }