-
Notifications
You must be signed in to change notification settings - Fork 595
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bug: opendal state store may not operate atomically #15154
Comments
If |
I think it depends. If a future cancellation or node crash occurs during the procedure, and there is also no defensive programming on the next startup, things could get wrong. The recent issue reported by a user is getting an empty file at the
risingwave/src/meta/src/hummock/manager/checkpoint.rs Lines 90 to 92 in 2593017
|
I see. I understand that this issue will cause the file content of an object to be empty or incorrect. We are debugging another case reported by a user when there is an object that is present in HummockVersion but absent in HDFS. I guess it is not relevant to this issue? |
I have no idea. 😕 |
fixed in #15155 |
Operations on S3/OSS are always atomic. For example, we'll never get partial objects uploaded to the object store.
However, this is not true for all
opendal
services by default. We may get the data corrupted if users are using opendal state store likehummock+fs://..
. This may lead to unexpected results as we also leverage state store for Hummock metadata management.It turns out that we should manually enable atomicity guarantee by setting the
atomic_write_dir
config when building services.https://docs.rs/opendal/latest/opendal/services/struct.Fs.html#method.atomic_write_dir
The text was updated successfully, but these errors were encountered: