Home

kafkacat

Kafkacat, now commonly referred to as kcat, is a lightweight command-line client for Apache Kafka. It provides both producer and consumer functionality and is built on top of librdkafka, the C/C++ Kafka client library. Developed by Edenhill, kafkacat is designed for quick testing, debugging, and scripting interactions with Kafka clusters.

The tool operates in two main modes: producer mode (-P) sends messages to a topic from standard

Kafkacat is built on librdkafka, which provides access to Kafka features such as partitions, offsets, topics,

In most distributions and repositories, the tool is now marketed under the name kcat, with kafkacat remaining

See also: Apache Kafka, librdkafka, kcat.

input
or
a
file;
consumer
mode
(-C)
reads
messages
from
a
topic
and
prints
them
to
standard
output.
It
supports
a
range
of
options
to
control
behavior,
including
specifying
bootstrap
servers
(-b),
topic
(-t),
and
starting
offset
(-o)
such
as
beginning
or
end.
End-of-partition
handling
can
be
managed
with
-e.
Output
formatting
can
be
customized
with
-f
and
a
key
delimiter
with
-K.
Configuration
options
can
be
supplied
with
-X,
and
consumer-group
consumption
can
be
performed
with
-G
to
specify
a
group.
and
metadata.
It
is
cross-platform
within
UNIX-like
systems
and
Windows
and
is
widely
used
for
ad-hoc
interactions,
broker
connectivity
testing,
producing
seed
data,
inspecting
topic
content
and
offsets,
and
for
scripting
in
batch
processes.
widely
recognized
in
historical
references.
The
two
names
refer
to
the
same
utility,
with
kcat
representing
the
contemporary
canonical
name
in
recent
releases.