Skip to content

Commit

Permalink
increase the max-write-buffer-size default value (OpenAtomFoundation#611
Browse files Browse the repository at this point in the history
)
  • Loading branch information
Axlgrep committed May 15, 2019
1 parent 5595d44 commit 6b4ca8d
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 1 deletion.
2 changes: 1 addition & 1 deletion conf/pika.conf
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ small-compaction-threshold : 5000
# If the total size of all live memtables of all the DBs exceeds
# the limit, a flush will be triggered in the next DB to which the next write
# is issued.
max-write-buffer-size : 2147483648
max-write-buffer-size : 10737418240
# Compression
compression : snappy
# max-background-flushes: default is 1, limited in [1, 4]
Expand Down
24 changes: 24 additions & 0 deletions src/pika_admin.cc
Original file line number Diff line number Diff line change
Expand Up @@ -879,6 +879,12 @@ void ConfigCmd::ConfigGet(std::string &ret) {
EncodeString(&config_body, g_pika_conf->db_path());
}

if (slash::stringmatch(pattern.data(), "trash-path", 1)) {
elements += 2;
EncodeString(&config_body, "trash-path");
EncodeString(&config_body, g_pika_conf->trash_path());
}

if (slash::stringmatch(pattern.data(), "maxmemory", 1)) {
elements += 2;
EncodeString(&config_body, "maxmemory");
Expand Down Expand Up @@ -1095,6 +1101,24 @@ void ConfigCmd::ConfigGet(std::string &ret) {
EncodeInt32(&config_body, g_pika_conf->binlog_file_size());
}

if (slash::stringmatch(pattern.data(), "max-cache-statistic-keys", 1)) {
elements += 2;
EncodeString(&config_body, "max-cache-statistic-keys");
EncodeInt32(&config_body, g_pika_conf->max_cache_statistic_keys());
}

if (slash::stringmatch(pattern.data(), "small-compaction-threshold", 1)) {
elements += 2;
EncodeString(&config_body, "small-compaction-threshold");
EncodeInt32(&config_body, g_pika_conf->small_compaction_threshold());
}

if (slash::stringmatch(pattern.data(), "max-write-buffer-size", 1)) {
elements += 2;
EncodeString(&config_body, "max-write-buffer-size");
EncodeInt64(&config_body, g_pika_conf->max_write_buffer_size());
}

if (slash::stringmatch(pattern.data(), "compression", 1)) {
elements += 2;
EncodeString(&config_body, "compression");
Expand Down

0 comments on commit 6b4ca8d

Please sign in to comment.