You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@kafka.apache.org by Sameer Kumar <sa...@gmail.com> on 2017/08/18 09:52:00 UTC
Question on Kafka Producer Transaction Id
Hi,
I have a question on Kafka transaction.id config related to atomic writes
feature of Kafka11. If I have multiple producers across different JVMs, do
i need to set transactional.id differently for each JVM. Does transaction.id
controls the begin and ending of transactions.
If its not set unique, how would the following case be handled.
T1.begin (Producer 1)
T1.begin (Producer 2)
T2.end (Producer 2)
T2.end (Producer 1)
-Sameer.
Re: Question on Kafka Producer Transaction Id
Posted by Sameer Kumar <sa...@gmail.com>.
Hi,
I just saw an example, does producer.initTransactions() takes care of this
part.
Also thinking if transactions are threadsafe as soon as i do begin and
commit local to a thread.
Please enlighten.
-Sameer.
On Fri, Aug 18, 2017 at 3:22 PM, Sameer Kumar <sa...@gmail.com>
wrote:
> Hi,
>
> I have a question on Kafka transaction.id config related to atomic writes
> feature of Kafka11. If I have multiple producers across different JVMs, do
> i need to set transactional.id differently for each JVM. Does
> transaction.id controls the begin and ending of transactions.
>
> If its not set unique, how would the following case be handled.
>
> T1.begin (Producer 1)
>
> T1.begin (Producer 2)
> T2.end (Producer 2)
> T2.end (Producer 1)
>
> -Sameer.
>