Skip to content

IGNITE-27091 Fix client tx rollback to ignore connection errors#7671

Open
ptupitsyn wants to merge 12 commits intoapache:mainfrom
ptupitsyn:ignite-27091
Open

IGNITE-27091 Fix client tx rollback to ignore connection errors#7671
ptupitsyn wants to merge 12 commits intoapache:mainfrom
ptupitsyn:ignite-27091

Conversation

@ptupitsyn
Copy link
Contributor

@ptupitsyn ptupitsyn commented Feb 26, 2026

When the client disconnects, server rolls back the transaction automatically, so it does not make sense to throw IgniteClientConnectionException from rollback or rollbackAsync.

@ptupitsyn ptupitsyn requested a review from Copilot February 26, 2026 08:51
@ptupitsyn ptupitsyn self-assigned this Feb 26, 2026
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR addresses connection error handling during client transaction rollback operations. When a client disconnects or the server becomes unavailable, rollback operations now gracefully ignore connection exceptions instead of throwing errors, since the transaction is effectively rolled back on the server side when the connection is lost.

Changes:

  • Modified client transaction rollback logic to catch and ignore IgniteClientConnectionException during rollback operations
  • Added integration test to verify rollback behavior when client disconnects
  • Added unit test to verify rollback behavior when server disconnects

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
ClientTransaction.java Wrapped rollback logic to catch connection exceptions and return successfully, recognizing that disconnection implies server-side rollback
ItThinClientTransactionsTest.java Added integration test verifying rollback succeeds after client disconnect for both sync and async cases
ClientTransactionsTest.java Added unit test verifying rollback succeeds after server disconnect for both sync and async cases

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

ptupitsyn and others added 5 commits February 26, 2026 11:35
…ansactionsTest.java

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…rnal/runner/app/client/ItThinClientTransactionsTest.java

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
# Conflicts:
#	modules/client/src/main/java/org/apache/ignite/internal/client/tx/ClientTransaction.java
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants