Improve sync error handling #698
All Vouch review confidence checks passed
Residual risk 0.33 = Change Risk (0.59) × (1 − Review Confidence (0.45)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.59 · 650 lines diff across 8 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.02 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.388
Shallow Review Depth
shallow_review_depth
0.344
Real PR Conversation Timeline
1 comments
"Review active on #698"
general
weight: 0.35
kucukaslan
The company I work for has encountered a problem where a sync failure just ends up deleting all destination files. I took it upon myself to examine the issue, and found someone else reported the same behavior in issue #695.
In testing different failure cases, I have found the following through log level of trace and adding an extra log to the source object retrieval section.
Test environment is a Ceph Object Gateway which contains some test files and folders to allow me to quickly sync a test data set. Then, I have a PHP script on my web server that triggers an error I saw when Ceph Object Store had an error.
Test PHP file:
First, I tested network related issues by rebooting my web server as s5cmd was in a retry loop, and I got the following error:
I added
RequestErrorto the list of awsErr codes inshouldStopSyncto make this error stop the sync.My next test is with the above PHP script to reproduce the following error we got when Ceph was in a bad state:
Testing with my debug code, and I get the following:
With the above, I have added
SerializationErrorto the list inshouldStopSync.To ensure sync cancels also cancels the plan run, I added the context as a parameter and added a context error check to cancel the plan when the context cancels.
Now to test that the changes mentioned actually fixes the problem. Testing the first failure case of network related issue:
Finally the second failure case of S3 backend failure: