66 const std::string& name,
67 engine::TaskProcessor& producer_task_processor,
68 const impl::ProducerConfiguration& configuration,
69 const impl::Secret& secrets
79 Producer(
const Producer&) =
delete;
80 Producer(Producer&&) =
delete;
82 Producer& operator=(
const Producer&) =
delete;
83 Producer& operator=(Producer&&) =
delete;
104 std::string_view key,
105 std::string_view message,
106 std::optional<std::uint32_t> partition = kUnassignedPartition,
107 HeaderViews headers = {}
126 template <
typename Messages>
128 std::is_convertible_v<
decltype(std::declval<
const Messages&>()[0]), std::string_view> &&
129 std::is_integral_v<
decltype(std::declval<
const Messages&>().size())> >
132 std::string_view key,
133 const Messages& messages,
134 std::optional<std::uint32_t> partition = kUnassignedPartition,
135 HeaderViews headers = {}
137 SendWrapper(topic_name, key, impl::MessagesAdapter{messages}, partition, std::move(headers));
149 std::string topic_name,
152 std::optional<std::uint32_t> partition = kUnassignedPartition,
153 HeaderViews headers = {}
164 std::string_view key,
165 std::string_view message,
166 std::optional<std::uint32_t> partition,
167 impl::HeadersHolder&& headers_holder
172 std::string_view key,
173 const impl::Messages& messages,
174 std::optional<std::uint32_t> partition,
175 std::vector<impl::HeadersHolder>&& headers_holders
180 std::string_view key,
181 const impl::Messages& messages,
182 std::optional<std::uint32_t> partition,
186 const std::string name_;
187 engine::TaskProcessor& producer_task_processor_;
189 static constexpr std::size_t kImplSize{944};
190 static constexpr std::size_t kImplAlign{16};
191 utils::FastPimpl<impl::ProducerImpl, kImplSize, kImplAlign> producer_;