You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
If a node uses the disk cache and tries to process a single transaction for the entire sync loop, the sync will break and the node will stop syncing.
Let node start syncing from a few thousands blocks behind the network. It won't get any new block and syncing won't go through.
Expected behavior
Node has to start syncing process and download the blocks until it reaches to current block
Additional context
The PR #4445 is combining the contexts, which can break disk access for ErigonDB. For example, it removes context.Background() and replaces it with a common context from stage.
to get the idea what is the reason of using background context, try writing a test with ErigonDB and creating a few goroutines, then commit some data to the same db. Your code has to open up a new transaction with another thread but same database and same context. It will not be able to write to disk while other routines are using the same database.
The text was updated successfully, but these errors were encountered:
Describe the bug
If a node uses the disk cache and tries to process a single transaction for the entire sync loop, the sync will break and the node will stop syncing.
To Reproduce
Steps to reproduce the behavior:
UseMemDB=false
canRunCycleInOneTransaction=true
(insyncing.go
underapi/service/stagedstreamsync
)-- later this flag will be set dynamically by PR update the hardcoded settings in stream sync #4448
Expected behavior
Node has to start syncing process and download the blocks until it reaches to current block
Additional context
The PR #4445 is combining the contexts, which can break disk access for ErigonDB. For example, it removes
context.Background()
and replaces it with a common context from stage.to get the idea what is the reason of using background context, try writing a test with ErigonDB and creating a few goroutines, then commit some data to the same db. Your code has to open up a new transaction with another thread but same database and same context. It will not be able to write to disk while other routines are using the same database.
The text was updated successfully, but these errors were encountered: