mirror of
https://github.com/dragonflydb/dragonfly.git
synced 2025-05-11 10:25:47 +02:00
chore: retire TEST_EnableHeartBeat (#3435)
Now unit tests will run the same Hearbeat fiber like in prod. The whole feature was redundant, with just few explicit settings of maxmemory_limit I succeeeded to make all unit tests pass. In addition, this change allows passing a global handler that is called by heartbeat from a single thread. This is not used yet - preparation for the next PR to break hung up replication connections on a master. Finally, this change has some non-functional clean-ups and warning fixes to improve code quality. Signed-off-by: Roman Gershman <roman@dragonflydb.io>
This commit is contained in:
parent
82298b8122
commit
c9ed3f7b2b
22 changed files with 56 additions and 100 deletions
|
@ -29,18 +29,10 @@ using facade::MemcacheParser;
|
|||
|
||||
class Service : public facade::ServiceInterface {
|
||||
public:
|
||||
struct InitOpts {
|
||||
bool disable_time_update;
|
||||
|
||||
InitOpts() : disable_time_update{false} {
|
||||
}
|
||||
};
|
||||
|
||||
explicit Service(util::ProactorPool* pp);
|
||||
~Service();
|
||||
|
||||
void Init(util::AcceptServer* acceptor, std::vector<facade::Listener*> listeners,
|
||||
const InitOpts& opts = InitOpts{});
|
||||
void Init(util::AcceptServer* acceptor, std::vector<facade::Listener*> listeners);
|
||||
|
||||
void Shutdown();
|
||||
|
||||
|
@ -93,7 +85,7 @@ class Service : public facade::ServiceInterface {
|
|||
GlobalState GetGlobalState() const;
|
||||
|
||||
void ConfigureHttpHandlers(util::HttpListenerBase* base, bool is_privileged) final;
|
||||
void OnClose(facade::ConnectionContext* cntx) final;
|
||||
void OnConnectionClose(facade::ConnectionContext* cntx) final;
|
||||
|
||||
Service::ContextInfo GetContextInfo(facade::ConnectionContext* cntx) const final;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue