Skip to content

Commit

Permalink
Set key if available
Browse files Browse the repository at this point in the history
  • Loading branch information
KonstantinCodes committed Jun 27, 2020
1 parent 3171fb0 commit f088800
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Messenger/KafkaTransport.php
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ public function send(Envelope $envelope): Envelope

$payload = $this->serializer->encode($envelope);

$topic->producev(RD_KAFKA_PARTITION_UA, 0, $payload['body'], null, $payload['headers'] ?? null);
$topic->producev(RD_KAFKA_PARTITION_UA, 0, $payload['body'], $payload['key'] ?? null, $payload['headers'] ?? null);

$producer->flush($this->flushTimeoutMs);

Expand Down

0 comments on commit f088800

Please sign in to comment.