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

feat: add wait for masternode-status "ready" #659

Merged
merged 8 commits into from
Jul 21, 2023

Conversation

shotonoff
Copy link
Collaborator

Issue being fixed or feature implemented

In some cases Tenderdash may crash if it runs in validator mode and it can't get pro-tx hash by some external reason.
As result, Tenderdash crashes and docker supervisor runs it again until node gets pro-tx hash

What was done?

Implement wait-for logic, that checks the masternode status until get READY. If the status is WAITING_FOR_PROTX then waits for 1 second and retry the operation, otherwise exit.

How Has This Been Tested?

The function covers with the test

Breaking Changes

N/A

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated relevant unit/integration/functional/e2e tests
  • I have made corresponding changes to the documentation

For repository code-owners and collaborators only

  • I have assigned this pull request to a milestone

dash/core/client.go Show resolved Hide resolved
dash/core/client.go Show resolved Hide resolved
dash/core/client.go Outdated Show resolved Hide resolved
@shotonoff shotonoff requested a review from lklimek July 19, 2023 07:50
Copy link
Collaborator Author

@shotonoff shotonoff left a comment

Choose a reason for hiding this comment

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

made modifications, please have a look at them

Copy link
Collaborator Author

@shotonoff shotonoff left a comment

Choose a reason for hiding this comment

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

answered to the comment

dash/core/client.go Show resolved Hide resolved
Copy link
Collaborator Author

@shotonoff shotonoff left a comment

Choose a reason for hiding this comment

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

answered

@shotonoff shotonoff merged commit e11684a into v0.12-dev Jul 21, 2023
15 checks passed
@shotonoff shotonoff deleted the td-171-wait-for-abci-is-ready branch July 21, 2023 08:46
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