-
Notifications
You must be signed in to change notification settings - Fork 58
Open
Description
According to the source code, the retry logic is implemented outside the apply_record function, which will be called by update_record.
sqllogictest-rs/sqllogictest/src/runner.rs
Lines 1010 to 1031 in 265f332
| // Retry for `retry.attempts` times. The parser ensures that `retry.attempts` must > 0. | |
| let retry = retry.unwrap(); | |
| let mut last_error = None; | |
| for _ in 0..retry.attempts { | |
| let result = self.run_async_no_retry(record.clone()).await; | |
| if result.is_ok() { | |
| return result; | |
| } | |
| tracing::warn!(target:"sqllogictest::retry", backoff = ?retry.backoff, error = ?result, "retrying"); | |
| D::sleep(retry.backoff).await; | |
| last_error = result.err(); | |
| } | |
| Err(last_error.unwrap()) | |
| } | |
| /// Run a single record without retry. | |
| async fn run_async_no_retry( | |
| &mut self, | |
| record: Record<D::ColumnType>, | |
| ) -> Result<RecordOutput<D::ColumnType>, TestError> { | |
| let result = self.apply_record(record.clone()).await; |
As a result, statements or queries with retry keyword cannot be updated to have the desired output.

Metadata
Metadata
Assignees
Labels
No labels