1
0
Fork 0

Let bootstrap feature publish its readiness.

This commit is contained in:
Max Neunhoeffer 2016-05-25 17:29:34 +02:00
parent e3bfe6ec76
commit 9b8f9f22e9
2 changed files with 9 additions and 1 deletions

View File

@ -40,7 +40,7 @@ using namespace arangodb::application_features;
using namespace arangodb::options;
BootstrapFeature::BootstrapFeature(application_features::ApplicationServer* server)
: ApplicationFeature(server, "Bootstrap") {
: ApplicationFeature(server, "Bootstrap"), _isReady(false) {
startsAfter("Dispatcher");
startsAfter("Endpoint");
startsAfter("Scheduler");
@ -148,6 +148,8 @@ void BootstrapFeature::start() {
arangodb::rest::HttpHandlerFactory::setMaintenance(false);
LOG(INFO) << "ArangoDB (version " << ARANGODB_VERSION_FULL
<< ") is ready for business. Have fun!";
_isReady = true;
}
void BootstrapFeature::stop() {

View File

@ -33,6 +33,12 @@ class BootstrapFeature final : public application_features::ApplicationFeature {
public:
void start() override final;
void stop() override final;
bool isReady() const {
return _isReady;
}
private:
bool _isReady;
};
}