mirror of https://gitee.com/bigwinds/arangodb
fix agency shutdown
This commit is contained in:
parent
85db0a062a
commit
667dc8af49
|
@ -229,8 +229,16 @@ void AgencyFeature::start() {
|
|||
_agent->load();
|
||||
}
|
||||
|
||||
void AgencyFeature::unprepare() {
|
||||
void AgencyFeature::beginShutdown() {
|
||||
if (!isEnabled()) {
|
||||
return;
|
||||
}
|
||||
|
||||
// pass shutdown event to _agent so it can notify all its sub-threads
|
||||
_agent->beginShutdown();
|
||||
}
|
||||
|
||||
void AgencyFeature::unprepare() {
|
||||
if (!isEnabled()) {
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -20,8 +20,8 @@
|
|||
/// @author Kaveh Vahedipour
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef ARANGOD_AGENCY_APPLICATION_AGENCY_H
|
||||
#define ARANGOD_AGENCY_APPLICATION_AGENCY_H 1
|
||||
#ifndef ARANGOD_AGENCY_AGENCY_FEATURE_H
|
||||
#define ARANGOD_AGENCY_AGENCY_FEATURE_H 1
|
||||
|
||||
#include "ApplicationFeatures/ApplicationFeature.h"
|
||||
|
||||
|
@ -40,6 +40,7 @@ class AgencyFeature : virtual public application_features::ApplicationFeature {
|
|||
void validateOptions(std::shared_ptr<options::ProgramOptions>) override final;
|
||||
void prepare() override final;
|
||||
void start() override final;
|
||||
void beginShutdown() override final;
|
||||
void unprepare() override final;
|
||||
|
||||
private:
|
||||
|
|
Loading…
Reference in New Issue