Skip to content
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

Propagate raft_recover errors and improve tracing #702

Merged
merged 1 commit into from
Sep 10, 2024

Conversation

petrutlucian94
Copy link
Contributor

At the moment, the raft_recover error messages are not propagated, so the caller gets a cryptic error code (1), without further details.

This change ensures that the error messages are propagated and adds a few extra trace messages.

Furthermore, tracing is disabled unless we start the node (not the case when we're actually trying to recover it). For now, we're adding a "dqliteTracingMaybeEnable" call in "dqlite_node_recover_ext".

@petrutlucian94
Copy link
Contributor Author

Related go-dqlite PR: canonical/go-dqlite#318

At the moment, the raft_recover error messages are not propagated,
so the caller gets a cryptic error code (1), without further
details.

This change ensures that the error messages are propagated and adds
a few extra trace messages.

Furthermore, tracing is disabled unless we start the node (not the
case when we're actually trying to recover it). For now, we're adding a
"dqliteTracingMaybeEnable" call in "dqlite_node_recover_ext".
Copy link

codecov bot commented Sep 10, 2024

Codecov Report

Attention: Patch coverage is 43.75000% with 9 lines in your changes missing coverage. Please review.

Project coverage is 85.67%. Comparing base (e6ac700) to head (72ff0be).
Report is 80 commits behind head on master.

Files with missing lines Patch % Lines
src/raft/uv.c 44.44% 5 Missing ⚠️
src/server.c 33.33% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #702      +/-   ##
==========================================
+ Coverage   77.87%   85.67%   +7.80%     
==========================================
  Files         197      197              
  Lines       27779    29096    +1317     
  Branches     5538     4089    -1449     
==========================================
+ Hits        21633    24929    +3296     
+ Misses       4420     3945     -475     
+ Partials     1726      222    -1504     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@cole-miller cole-miller self-requested a review September 10, 2024 14:14
Copy link
Contributor

@cole-miller cole-miller left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the contribution, this looks good!

@cole-miller cole-miller merged commit baf5865 into canonical:master Sep 10, 2024
19 of 20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants