OSS TanbouSign in with GitHub

standardize Kafka producers, consumers, retries, and transactions through Spring abstractions

About these scores

OSS scale score is an unbounded metric that log-compresses and weights Stars, Watchers, Forks, and Contributors. Discovery score is the current OSS scale score minus the score at discovery. Update pace is commits in the last 30 days, growth momentum is the OSS scale score difference within the recent observation window, and OSS health is a 0–100 rating based on available recency, Community Health, and release data.

Stars
2,512
Primary language
Java
License
Apache-2.0
Repository last updated
Oct 6, 2026
On this page

Overview

Spring for Apache Kafka wraps the Apache Kafka client in Spring-oriented APIs. It provides KafkaTemplate, @KafkaListener, listener containers, error handlers, transactions, non-blocking retry, Kafka Streams integration, and testing utilities.

Features and best fit

Based on official documentation; not hands-on tested · Content checked:

Key features

Build producers and consumers with KafkaTemplate and @KafkaListener

The core module provides KafkaTemplate, @KafkaListener, single- and multi-threaded listener containers, KafkaAdmin, producer factories, and consumer factories.

Sources: [2]

Integrate retry topics, transactions, and test utilities

The project includes @RetryableTopic for non-blocking retries and dead-letter routing, KafkaTransactionManager support, EmbeddedKafkaBroker, and JUnit-oriented test utilities.

Sources: [2]

Best fit

Fits Spring Boot and Kotlin event-driven services standardizing Kafka operations

It is useful when producer/consumer factories, listener lifecycles, error handling, retries, and transactions should be managed through Spring configuration.

Sources: [2][1]

Before adoption

Design retry, acknowledgment, and transaction behavior as a delivery policy

Listener containers, AckMode, error handlers, retry topics, and transactions offer multiple delivery choices, so applications should define at-least-once handling, idempotency, and DLT policies explicitly.

Sources: [2]

Version 4.1.1 includes CVE fixes for Kafka header handling

The v4.1.1 release hardens retry/backoff timestamp headers, restricts certain java.net types in header type mapping, and includes fixes for issues such as records being lost during retry.

Sources: [3]

Official sources

  1. [1]Spring Kafka README(2026-10-06)
  2. [2]Spring Kafka module structure(2026-10-06)
  3. [3]Spring Kafka v4.1.1 release(2026-10-06)
Supplemental curator note

It fits Spring Boot and Kotlin services that want Kafka producers and consumers integrated with Spring configuration and error handling. Version 4.1.1 includes CVE fixes around Kafka header handling.

Try it in 3 steps

  1. 1

    Get the source

    git clone --depth 1 https://github.com/spring-projects/spring-kafka.git
  2. 2

    Enter the repository

    cd spring-kafka
  3. 3

    Check the official steps

    Continue with the commands in the README Installation, Quick Start, or Getting Started section.

    find . -maxdepth 1 -iname 'README*' -exec sed -n '1,220p' {} \; -quit
Check the official README

Growth

Growth trends · Last 30 days

2,512 Stars

Trend data is still being collected.

Development activity

Last 90 days · weekly

Commits (last 30 days)
61
Open PRs
9

Development activity is still being collected.

Built with

Categories and tags

Categories

GitHub data

GitHub dataView detailed GitHub data
Stars
2,512
Forks
1,770
Watchers
148
Open issues
30
Contributors
274
Owner type
Organization
Primary language
Java
License
Apache-2.0
Repository last updated
Oct 6, 2026
Write a related article

Share a guide or use case for this OSS in Markdown. Articles are published after administrator approval.

Report incorrect information

Tell us if any listing information is incorrect or outdated.

After reading this page, do you know what to do next?