mirror of
https://github.com/dragonflydb/dragonfly.git
synced 2025-05-11 10:25:47 +02:00
chore: get rid of cmdstats_map (#1687)
cmdstats_map were on the hotpath and are needed only to update the command stats. Instead, I introduced the stats withing the CommandId itself that we lookup anyways. Also, it removes fragile dependency on naked command name char* pointers. Signed-off-by: Roman Gershman <roman@dragonflydb.io>
This commit is contained in:
parent
3a832b5620
commit
a743d7577a
7 changed files with 69 additions and 28 deletions
|
@ -68,6 +68,10 @@ class Service : public facade::ServiceInterface {
|
|||
return registry_.Find(cmd);
|
||||
}
|
||||
|
||||
CommandRegistry* mutable_registry() {
|
||||
return ®istry_;
|
||||
}
|
||||
|
||||
facade::ErrorReply ReportUnknownCmd(std::string_view cmd_name);
|
||||
|
||||
// Returns: the new state.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue