mirror of
https://github.com/neondatabase/neon.git
synced 2025-12-22 21:59:59 +00:00
libs: make remote storage failure injection probabilistic (#12526)
Change the unreliable storage wrapper to fail by probability when there are more failure attempts left. Co-authored-by: Yecheng Yang <carlton.yang@databricks.com>
This commit is contained in:
@@ -267,7 +267,7 @@ async fn worker_inner(
|
||||
) -> anyhow::Result<()> {
|
||||
#[cfg(any(test, feature = "testing"))]
|
||||
let storage = if config.test_remote_failures > 0 {
|
||||
GenericRemoteStorage::unreliable_wrapper(storage, config.test_remote_failures)
|
||||
GenericRemoteStorage::unreliable_wrapper(storage, config.test_remote_failures, 100)
|
||||
} else {
|
||||
storage
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user