Transactional Rollback Strategies with Spring Cloud Stream and Apache Kafka

Engineering | Soby Chacko | October 11, 2023 | ...

Other parts in this blog series

Part 1: Introduction to Transactions in Spring Cloud Stream Kafka Applications

Part 2: Producer Initiated Transactions in Spring Cloud Stream Kafka Applications

Part 3: Synchronizing with External Transaction Managers in Spring Cloud Stream Kafka Applications

In the last three sections of this blog series, we analyzed how transactions work in Spring Cloud Stream Kafka applications. We encountered different contexts in which transactions are helpful, including both producer and consumer applications and how an application can correctly use them. Now that those fundamental elements are behind us, let’s move on to another aspect of transactions: rolling back a transaction when an error occurs. When an error occurs and a transactional system cannot commit the transaction, the transaction manager rolls back the transaction and does not persist anything for a downstream consumer to see. It would help if an application could dictate how this rollback mechanism works. Spring Cloud Stream facilitates this rollback…

This Week in Spring - October 10th, 2023

Engineering | Josh Long | October 10, 2023 | ...

Hi, Spring fans! Welcome to another installment of This Week in Spring! Last week I was in Antwerp, Belgium, for the amazing Devoxx Belgium event, and this week I've been in Amsterdam for the SpringOne Tour Amsterdam stop and - in the middle of the SpringOne Tour Amsterdam event - I dipped out to join my friend and fellow Java Champion Trustin Lee (@trustin) (he created Netty! the guy's a living legend!) for a discussion and ask-me-anything at the local Amsterdam Java User Group, hosted by fellow Java Champion and local Geertjan Wielenga (@GeertjanW). It was a lovely day indeed across the two…

Synchronizing with External Transaction Managers in Spring Cloud Stream Kafka Applications

Engineering | Soby Chacko | October 04, 2023 | ...

Other parts in this blog series

Part 1: Introduction to Transactions in Spring Cloud Stream Kafka Applications

Part 2: Producer Initiated Transactions in Spring Cloud Stream Kafka Applications

In the previous part of this blog series, we saw the basics of transaction management, primarily when using producer-initiated Spring Cloud Stream Kafka applications. In that discussion, we also briefly saw how a Spring Cloud Stream Kafka consumer application could consume records produced transactionally with proper isolation levels. When you synchronize with external transaction managers, such as one…

Spring Shell 2.1.13, 3.0.8 and 3.1.4 are now available

Releases | Janne Valkealahti | October 04, 2023 | ...

Spring Shell 2.1.13, 3.0.8 and 3.1.4 are now available

On behalf of the team and everyone who has contributed, I'm happy to announce that Spring Shell 2.1.13, 3.0.8 and 3.1.4 has been released and are now available from Maven Central.

Please see the release notes 2.1.13, release notes 3.0.8 and release notes 3.1.4 for more details.

Thanks to all those who have contributed with issue reports and pull requests.

How can you help?

Project Page | GitHub | Issues | Documentation

This Week in Spring - October 3rd, 2023

Engineering | Josh Long | October 03, 2023 | ...

Hi Spring fans! Welcome to another installment of This Week in Spring! How're you doin'? I've just flown in from Singapore - where I was keynoting and presenting at SpringOne Singapore - and am now in Antwerp, Belgium for the deliriously fun Devoxx Belgium show. I've missed this show, and it's a true pleasure to be back here! Next week, I'll be in Amsterdam, just next door, for the SpringOne Tour Amsterdam. If you're there, come out and say hi!

We've got a lot of stuff to look at this morning, so let's dive right into it.

Spring Cloud 2023.0.0-M2 (aka Leyton) has been released

Releases | Olga Maciaszek-Sharma | September 29, 2023 | ...

On behalf of the community, I am pleased to announce that the Milestone 2 (M2) of the Spring Cloud 2023.0 Release Train is available today. The release can be found in Spring Milestone repository. You can check out the 2023.0 release notes for more information.

Notable Changes in the 2023.0.0-M2 Release Train

In this milestone, we have migrated the documentation of all the Spring Cloud projects to Antora.

See all issues and pull requests here.

Spring Cloud Commons

  • Refresh Scope on restart - a feature tailored to allow adapting to environment changes on JVM Checkpoint-Restart (PR 1266)

Spring…

Producer Initiated Transactions in Spring Cloud Stream Kafka Applications

Engineering | Soby Chacko | September 28, 2023 | ...

Other parts in this blog series

Part 1: Introduction to Transactions in Spring Cloud Stream Kafka Applications

This article is part 2 of the blog series in which we look at transactions in detail with Spring Cloud Stream and Apache Kafka. We saw a general introduction to transactions in the previous part, touching on the fundamental ideas. In this part of the blog series, we get to the metal by seeing a few implementation details and their practical aspects.

In this article, we largely stay on the producer's side to understand how transactions work with Spring Cloud Stream and Apache Kafka.

Introduction to Transactions in Spring Cloud Stream Kafka Applications

Engineering | Soby Chacko | September 27, 2023 | ...

We are starting a new blog series that focuses on working with transactions in Spring Cloud Stream Kafka applications. This blog series covers many low-level details of writing transactional applications with Spring Cloud Stream and Apache Kafka. By the end of this blog series, we hope to give you enough information about writing transactional Spring Cloud Stream Kafka applications for various business use cases.

Basic Building Blocks

The foundational support for transactions in Spring Cloud Stream Kafka applications primarily comes from Apache Kafka itself and the Spring for Apache Kafka…

Get the Spring newsletter

Thank you for your interest. Someone will get back to you shortly.

Get ahead

VMware offers training and certification to turbo-charge your progress.

Learn more

Get support

Tanzu Spring Runtime offers support and binaries for OpenJDK™, Spring, and Apache Tomcat® in one simple subscription.

Learn more

Upcoming events

Check out all the upcoming events in the Spring community.

View all