chore(efcore): implement sync versions of Retry methods#781
Conversation
This is the first step in a multi-step change to natively support synchronous versions of the Retry methods for aborted transactions. This step adds support for a sync version of the Retry method for DML and Batch DML statements.
There was a problem hiding this comment.
Code Review
This pull request introduces synchronous Retry methods to the IRetriableStatement interface and its implementations, along with a comprehensive suite of unit tests to verify their behavior. The review feedback suggests explicitly setting the transaction on the command in FailedBatchDmlStatement.Retry for consistency, and simplifying the exception assertions in the unit tests by using xUnit's Assert.Throws<T> instead of manual try-catch blocks.
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request introduces synchronous Retry methods to the IRetriableStatement interface and its various implementations (FailedBatchDmlStatement, FailedDmlStatement, RetriableBatchDmlStatement, RetriableDmlStatement, and SpannerDataReaderWithChecksum), along with corresponding unit tests. The review feedback highlights that the timeoutSeconds parameter is currently ignored across all these new Retry implementations, and recommends setting the CommandTimeout property on the underlying commands before execution to ensure timeouts are respected.
|
/gemini review |
There was a problem hiding this comment.
Code Review
This pull request introduces synchronous retry support to the IRetriableStatement interface and its implementations (FailedBatchDmlStatement, FailedDmlStatement, RetriableBatchDmlStatement, RetriableDmlStatement, and SpannerDataReaderWithChecksum). It also adds a comprehensive suite of unit tests in RetriableStatementsTests.cs to verify the behavior of these synchronous retries under various success and failure scenarios. I have no feedback to provide as there are no review comments to assess.
This is the first step in a multi-step change to natively support synchronous versions of the Retry methods for aborted transactions. This step adds support for a sync version of the Retry method for DML and Batch DML statements.