feat: introduce config set command (#1574)

feat: introduce "config set" command

Solves #1551. In detail, we introduce ConfigRegistry that holds
a curated set of flags that could be changed at run-time.

Signed-off-by: Roman Gershman <roman@dragonflydb.io>
This commit is contained in:
Roman Gershman 2023-07-20 15:55:39 +03:00 committed by GitHub
parent 9698d6fea2
commit 0fe6e36f25
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 162 additions and 150 deletions

View file

@ -9,6 +9,7 @@
#include "facade/service_interface.h"
#include "server/cluster/cluster_family.h"
#include "server/command_registry.h"
#include "server/config_registry.h"
#include "server/engine_shard_set.h"
#include "server/server_family.h"
@ -19,8 +20,8 @@ class AcceptServer;
namespace dfly {
class Interpreter;
class ObjectExplorer; // for Interpreter
using facade::MemcacheParser;
class Service : public facade::ServiceInterface {
public:
using error_code = std::error_code;
@ -151,4 +152,7 @@ class Service : public facade::ServiceInterface {
GlobalState global_state_ = GlobalState::ACTIVE; // protected by mu_;
};
uint64_t GetMaxMemoryFlag();
void SetMaxMemoryFlag(uint64_t value);
} // namespace dfly