Skip to content

Files

Latest commit

Apr 30, 2025
5ac084d · Apr 30, 2025

History

History

examples

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
Oct 9, 2024
Oct 9, 2024
Oct 9, 2024
Sep 27, 2023
Jan 13, 2023
Apr 30, 2025
Jun 29, 2023
Sep 27, 2023
Apr 15, 2025
Oct 24, 2023
Oct 9, 2024
Sep 29, 2016
Jun 29, 2023
Apr 30, 2025
Apr 30, 2025
Jan 13, 2023
Oct 4, 2024
Oct 24, 2023
Jan 4, 2023
Apr 30, 2025
Jun 29, 2023
Apr 30, 2025
Jun 29, 2023
Jun 29, 2023
Jun 29, 2023
Jun 29, 2023
Jun 29, 2023
Jun 29, 2023
Jun 29, 2023
Jun 29, 2023
Apr 30, 2025
Apr 30, 2025

librdkafka examples

This directory contains example applications utilizing librdkafka. The examples are built by running make and they will be be linked statically or dynamically to librdkafka in the parent ../src directory.

Begin with the following examples:

  • consumer.c - a typical C high-level consumer application.
  • producer.c - a typical C producer application.
  • producer.cpp - a typical C++ producer application.
  • idempotent_producer.c - Idempotent producer.
  • transactions.c - Full exactly once semantics (EOS) transactional consumer-producer exammple. Requires Apache Kafka 2.5 or later.
  • transactions-older-broker.c - Same as transactions.c but for Apache Kafka versions 2.4.x and older which lack KIP-447 support.
  • misc.c - a collection of miscellaneous usage examples.

For more complex uses, see:

For Admin API examples see: