Add bigger buffers for shred column families in rocks (#5653)
automerge
This commit is contained in:
parent
81bb208a62
commit
28f2c75137
|
@ -464,11 +464,11 @@ impl std::convert::From<rocksdb::Error> for Error {
|
||||||
}
|
}
|
||||||
|
|
||||||
fn get_cf_options(name: &'static str) -> Options {
|
fn get_cf_options(name: &'static str) -> Options {
|
||||||
use crate::blocktree::db::columns::{Coding, Data};
|
use crate::blocktree::db::columns::{Coding, Data, ShredCode, ShredData};
|
||||||
|
|
||||||
let mut options = Options::default();
|
let mut options = Options::default();
|
||||||
match name {
|
match name {
|
||||||
Coding::NAME | Data::NAME => {
|
Coding::NAME | Data::NAME | ShredCode::NAME | ShredData::NAME => {
|
||||||
// 512MB * 8 = 4GB. 2 of these columns should take no more than 8GB of RAM
|
// 512MB * 8 = 4GB. 2 of these columns should take no more than 8GB of RAM
|
||||||
options.set_max_write_buffer_number(8);
|
options.set_max_write_buffer_number(8);
|
||||||
options.set_write_buffer_size(MAX_WRITE_BUFFER_SIZE as usize);
|
options.set_write_buffer_size(MAX_WRITE_BUFFER_SIZE as usize);
|
||||||
|
|
Loading…
Reference in New Issue