package initialize import ( "codeword/internal/kafka/tariff" "github.com/twmb/franz-go/pkg/kgo" "go.uber.org/zap" ) type BrokersDeps struct { Logger *zap.Logger TariffClient *kgo.Client Topic string } type Brokers struct { TariffProducer *tariff.Producer } func NewBrokers(deps BrokersDeps) *Brokers { return &Brokers{ TariffProducer: tariff.NewProducer(tariff.ProducerDeps{ Logger: deps.Logger, Client: deps.TariffClient, Topic: deps.Topic, }), } }