-
Notifications
You must be signed in to change notification settings - Fork 35
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
Use rocks db as cache #139
Conversation
Daksh14
commented
May 9, 2023
•
edited
Loading
edited
- Use rocks db as cache
- Seperate the cache database per network. Create new db for different network and so on.
639691b
to
c3c40e1
Compare
Pinging @goshawk-3 as you have experience with rocksdb, here we are using it as a persistent disk database for caching data. Any reviews? This PR will pass once #140 is merged |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If this PR won't work alone, close #140 and apply those changes here directly.
Furthermore, change PR and commit descriptions in order to specify which issue(s) will be resolved
Cargo.toml
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Any reason to not remove microkelvin
?
src/cache.rs
Outdated
} | ||
|
||
let mut key_data = self.data.get_mut(&psk)?.expect("psk"); | ||
self.write_batch.put(psk_bytes, data.encode_to_vec()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Having the whole note set encoded into a singled field/row is something we would like to avoid (mostly to prevent tech-debt that will be raised when we'll start to handle rollback and note tagging).
… of more than 255 addresses
@goshawk-3 @herr-seppia @ZER0 |