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

Fix stuck monitor recovery. Avoid DB related deadlocks. #1098

Merged
merged 37 commits into from
Oct 17, 2024

Conversation

badrogger
Copy link
Contributor

@badrogger badrogger commented Aug 8, 2024

Changes:

  1. Added stuck recovery mechanism for config/skaled schains pipelines.
  2. Switch to writing alive timestamp to a file instead of the db.
  3. Remove locks from db read/write operations.

Performance:

  1. No additional major computation or IO operations were introduced.

Tests:

  1. Added additional unit tests.
  2. Tested on the local network.

Copy link

codecov bot commented Aug 28, 2024

Codecov Report

Attention: Patch coverage is 81.17647% with 64 lines in your changes missing coverage. Please review.

Project coverage is 83.22%. Comparing base (ad492d3) to head (0ac7970).
Report is 38 commits behind head on v2.8.x.

Files with missing lines Patch % Lines
core/schains/monitor/main.py 82.56% 19 Missing ⚠️
core/schains/process.py 79.34% 19 Missing ⚠️
core/schains/monitor/tasks.py 87.87% 8 Missing ⚠️
web/models/schain.py 80.55% 7 Missing ⚠️
core/schains/process_manager.py 72.72% 6 Missing ⚠️
core/schains/monitor/config_monitor.py 0.00% 2 Missing ⚠️
core/schains/monitor/skaled_monitor.py 0.00% 2 Missing ⚠️
core/schains/cleaner.py 83.33% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           v2.8.x    #1098      +/-   ##
==========================================
+ Coverage   82.00%   83.22%   +1.22%     
==========================================
  Files         102      102              
  Lines        6124     6267     +143     
==========================================
+ Hits         5022     5216     +194     
+ Misses       1102     1051      -51     

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

@badrogger badrogger linked an issue Aug 30, 2024 that may be closed by this pull request
@badrogger badrogger marked this pull request as ready for review August 30, 2024 12:28
@badrogger badrogger changed the base branch from develop to v2.8.x September 19, 2024 16:06
DimaStebaev
DimaStebaev previously approved these changes Oct 14, 2024
core/schains/monitor/main.py Outdated Show resolved Hide resolved
core/schains/monitor/main.py Outdated Show resolved Hide resolved
core/schains/monitor/tasks.py Outdated Show resolved Hide resolved
core/schains/process_manager_helper.py Show resolved Hide resolved
core/schains/process.py Outdated Show resolved Hide resolved
core/schains/process.py Show resolved Hide resolved
@DmytroNazarenko DmytroNazarenko merged commit d2ba47f into v2.8.x Oct 17, 2024
3 of 5 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.

Skale admin doesn't restart schain monitoring if monitoring hangs
4 participants