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

[Bug Report]The destruction process in sync is asynchronous, leading to the lock file being locked when the sync is triggered. #4348

Closed
jackzhhuang opened this issue Dec 13, 2024 · 0 comments · Fixed by #4347
Assignees
Labels
bug Something isn't working

Comments

@jackzhhuang
Copy link
Collaborator

Bug Report

In sync, when the block fetcher tries to get a block from the remote, if it fails and the retry time gets over limit, the sync process will end in failure and sends a notification to clear the state of sync. But this action is asynchronous, if the sync is triggered, for example, a new block notification comes, the sync will try restart. At this moment, the release of last sync process is not done, making the new process fails at trying to lock the sync database file.

To solve this, the handle of the sync database should be held by the sync service not the thread of sync.

image image

Starcoin version:

Current behavior:

Expected behavior:

Steps to reproduce:

Related code:

insert short code snippets here

Other information:

@jackzhhuang jackzhhuang added the bug Something isn't working label Dec 13, 2024
@jackzhhuang jackzhhuang self-assigned this Dec 13, 2024
@jackzhhuang jackzhhuang linked a pull request Dec 13, 2024 that will close this issue
7 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant