-
Notifications
You must be signed in to change notification settings - Fork 3k
TDBStore: Perform garbage collection on failed writes #9200
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
TDBStore: Perform garbage collection on failed writes #9200
Conversation
@davidsaada, thank you for your changes. |
@davidsaada Very good solution. We need to enhance the triggering of GC to the case a failure was not detected by the software and you will not get a return error. I think we should check the checksum at the end of set_finalize |
aea5c7f
to
37f10ab
Compare
Added read verification following @dannybenor's comment. |
CI started |
Test run: FAILEDSummary: 1 of 11 test jobs failed Failed test jobs:
|
CI restarted |
@davidsaada Please take a look at the greentea test failures: http://mbed-os-ci.s3-website-eu-west-1.amazonaws.com/?prefix=jenkins-ci/artifacts/9200/1/greentea-test/685/FAIL/ The K64F looks related to the PR, don't think the NRF52 is. |
Partial writes may turn storage unusable. GC clears this scenario.
37f10ab
to
72f6f6c
Compare
The NRF52 failure is indeed not related to the PR. |
CI restarated |
Test run: FAILEDSummary: 1 of 11 test jobs failed Failed test jobs:
|
Exporters restarted (pipeline closed error) |
Tests passed, what shall we do now? |
I think this should merge now. Only thing I can think for that failure was a one time glitch in the storage, which was covered by the missing error code checking. |
I think this PR should be merged |
Description
In TDBStore, partial writes may turn the storage unusable, as records are written sequentially. This change adds garbage collection following each write failure, in order to prevent such a scenario.
Pull request type