-
Notifications
You must be signed in to change notification settings - Fork 62
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
rusk-wallet: Rocksdb slowing this cli down #2511
Comments
I disagree about this being a bug. Furthermore the creation of the column families happens only when the cache database file is created, and not every time that it's instantiated Does flamegraph report the same if you use the wallet with an existing cache? (Just to mimic the everyday usecase) |
@herr-seppia This is not a bug for sure. The problem only happens when creating/deleting cf(s) which happens only when initiating the cache. If a user decides to change networks on the wallet which includes everyday use case, it will take quite a long time to do so. Edit: This is wrong, we can just add a warning on first init that this process is gonna take a while |
@Daksh14 Do you believe that this hint would be enough to tackle this issue? |
Yes because after that last heights are updated and we fetch from there. So it won't be as overhead heavy as the first sync. |
Flamegraph says:
We create column families for all 255 addresses everytime we initiate a cache database. That's not very efficient.
Second reason is that rocksdb works best when there's few column families only.
Currently we have 255. According to benchmark in the issue, that should take close to a minute to be done. That is super slow.
Find a way to reduce column families all together is one way to solve this problem.
We insert all 255 on every db init, a user might not use that many, we can only insert the cf(s) that are being used
The text was updated successfully, but these errors were encountered: