1
0
Fork 0

more const unification

This commit is contained in:
jsteemann 2016-01-15 00:09:52 +01:00
parent f66eb007cd
commit 1b959c827d
105 changed files with 19 additions and 946 deletions

View File

@ -44,15 +44,9 @@ RestActionHandler::RestActionHandler(HttpRequest* request,
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestActionHandler::isDirect() const { return _action == nullptr; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestActionHandler::execute() {
TRI_action_result_t result;
@ -98,9 +92,6 @@ HttpHandler::status_t RestActionHandler::execute() {
return status_t(result.isValid ? HANDLER_DONE : HANDLER_FAILED);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestActionHandler::cancel() { return _action->cancel(&_dataLock, &_data); }

View File

@ -57,21 +57,12 @@ class RestActionHandler : public RestVocbaseBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool cancel() override;

View File

@ -60,9 +60,6 @@ RestAqlHandler::RestAqlHandler(triagens::rest::HttpRequest* request,
size_t RestAqlHandler::queue() const { return Dispatcher::AQL_QUEUE; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestAqlHandler::isDirect() const { return false; }

View File

@ -53,15 +53,9 @@ class RestAqlHandler : public arango::RestVocbaseBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
size_t queue() const override;

View File

@ -81,9 +81,6 @@ ApplicationCluster::~ApplicationCluster() {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationCluster::setupOptions(
std::map<std::string, basics::ProgramOptionsDescription>& options) {
@ -113,9 +110,6 @@ void ApplicationCluster::setupOptions(
"disable the kickstarter functionality");
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationCluster::prepare() {
// set authentication data
@ -275,9 +269,6 @@ bool ApplicationCluster::prepare() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationCluster::start() {
if (!enabled()) {
@ -373,9 +364,6 @@ bool ApplicationCluster::start() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationCluster::open() {
if (!enabled()) {
@ -487,9 +475,6 @@ bool ApplicationCluster::open() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationCluster::close() {
if (!enabled()) {
@ -507,9 +492,6 @@ void ApplicationCluster::close() {
comm.sendServerState(0.0);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationCluster::stop() {
if (!enabled()) {

View File

@ -74,39 +74,21 @@ class ApplicationCluster : public rest::ApplicationFeature {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void setupOptions(std::map<std::string, basics::ProgramOptionsDescription>&);
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool prepare();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool open();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool start();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void close();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void stop();

View File

@ -44,15 +44,9 @@ RestShardHandler::RestShardHandler(triagens::rest::HttpRequest* request,
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestShardHandler::isDirect() const { return true; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
triagens::rest::HttpHandler::status_t RestShardHandler::execute() {
// Deactivated to allow for asynchronous cluster internal communication

View File

@ -47,9 +47,6 @@ class RestShardHandler : public admin::RestBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override;

View File

@ -64,9 +64,6 @@ ServerJob::ServerJob(HeartbeatThread* heartbeat, TRI_server_t* server,
ServerJob::~ServerJob() {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ServerJob::work() {
LOG_TRACE("starting plan update handler");
@ -89,15 +86,9 @@ void ServerJob::work() {
_heartbeat->removeDispatchedJob(result);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ServerJob::cancel() { return false; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ServerJob::cleanup(DispatcherQueue* queue) {
queue->removeJob(this);

View File

@ -78,36 +78,21 @@ class ServerJob : public triagens::rest::Job {
inline bool isDetached() const { return true; }
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void work() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool cancel() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void cleanup(rest::DispatcherQueue* queue) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool beginShutdown() {
_shutdown = 1;
return true;
}
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void handleError(basics::Exception const& ex) override {}

View File

@ -167,9 +167,6 @@ void ApplicationDispatcher::setProcessorAffinity(std::vector<size_t> const& core
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationDispatcher::setupOptions(
std::map<std::string, ProgramOptionsDescription>& options) {
@ -178,9 +175,6 @@ void ApplicationDispatcher::setupOptions(
"dispatcher report interval");
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationDispatcher::prepare() {
if (_disabled) {
@ -192,9 +186,6 @@ bool ApplicationDispatcher::prepare() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationDispatcher::start() {
if (_disabled) {
@ -206,15 +197,9 @@ bool ApplicationDispatcher::start() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationDispatcher::open() { return true; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationDispatcher::close() {
if (_disabled) {
@ -226,9 +211,6 @@ void ApplicationDispatcher::close() {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationDispatcher::stop() {
if (_disabled) {

View File

@ -101,39 +101,21 @@ class ApplicationDispatcher : virtual public ApplicationFeature {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void setupOptions(std::map<std::string, basics::ProgramOptionsDescription>&);
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool prepare();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool start();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool open();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void close();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void stop();

View File

@ -64,9 +64,6 @@ DispatcherThread::DispatcherThread(DispatcherQueue* queue)
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void DispatcherThread::run() {
currentDispatcherThread = this;
@ -130,9 +127,6 @@ void DispatcherThread::run() {
_queue->removeStartedThread(this);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void DispatcherThread::addStatus(VPackBuilder* b) {
Thread::addStatus(b);

View File

@ -65,15 +65,9 @@ class DispatcherThread : public basics::Thread {
protected:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void run();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void addStatus(arangodb::velocypack::Builder* b);

View File

@ -151,7 +151,7 @@ static bool AllocateSlotList(TRI_fulltext_handles_t* const handles,
////////////////////////////////////////////////////////////////////////////////
TRI_fulltext_handles_t* TRI_CreateHandlesFulltextIndex(
const uint32_t slotSize) {
uint32_t slotSize) {
TRI_fulltext_handles_t* handles =
static_cast<TRI_fulltext_handles_t*>(TRI_Allocate(
TRI_UNKNOWN_MEM_ZONE, sizeof(TRI_fulltext_handles_t), false));

View File

@ -132,7 +132,7 @@ static void FreeFollowers(index_t* const, node_t*);
static void FreeNode(index_t* const, node_t*);
static size_t MemorySubNodeList(const uint32_t);
static size_t MemorySubNodeList(uint32_t);
////////////////////////////////////////////////////////////////////////////////
@ -140,7 +140,7 @@ static size_t MemorySubNodeList(const uint32_t);
////////////////////////////////////////////////////////////////////////////////
#if TRI_FULLTEXT_DEBUG
void Indent(const uint32_t level) {
void Indent(uint32_t level) {
uint32_t i;
for (i = 0; i < level; ++i) {
@ -212,7 +212,7 @@ void DumpNode(const node_t* const node, uint32_t level) {
/// "good" boundary
////////////////////////////////////////////////////////////////////////////////
static inline size_t Padding(const uint32_t numEntries) {
static inline size_t Padding(uint32_t numEntries) {
#ifdef FULLTEXT_PADDING
size_t offset = sizeof(uint8_t) + // numAllocated
sizeof(uint8_t) + // numUsed
@ -357,8 +357,8 @@ static uint32_t NodeNumAllocated(const node_t* const node) {
/// @brief initialize a sub-node list with length information
////////////////////////////////////////////////////////////////////////////////
static void InitializeSubNodeList(void* data, const uint32_t numAllocated,
const uint32_t numFollowers) {
static void InitializeSubNodeList(void* data, uint32_t numAllocated,
uint32_t numFollowers) {
uint8_t* head = (uint8_t*)data;
*(head++) = (uint8_t)numAllocated;
@ -426,7 +426,7 @@ static inline node_t** NodeFollowersNodes(const node_t* const node) {
////////////////////////////////////////////////////////////////////////////////
static inline node_t** FollowersNodesPos(void* data,
const uint32_t numAllocated) {
uint32_t numAllocated) {
uint8_t* head = (uint8_t*)data;
uint8_t* keys = (uint8_t*)(head + 2); // numAllocated + numEntries
@ -438,7 +438,7 @@ static inline node_t** FollowersNodesPos(void* data,
/// specific length
////////////////////////////////////////////////////////////////////////////////
static size_t MemorySubNodeList(const uint32_t numEntries) {
static size_t MemorySubNodeList(uint32_t numEntries) {
return sizeof(uint8_t) + // numAllocated
sizeof(uint8_t) + // numEntries
((sizeof(node_char_t) + sizeof(node_t*)) *
@ -452,8 +452,8 @@ static size_t MemorySubNodeList(const uint32_t numEntries) {
////////////////////////////////////////////////////////////////////////////////
static bool ExtendSubNodeList(index_t* const idx, node_t* const node,
const uint32_t numFollowers,
const uint32_t numAllocated) {
uint32_t numFollowers,
uint32_t numAllocated) {
size_t nextSize;
uint32_t nextAllocated;
@ -939,7 +939,7 @@ static inline TRI_fulltext_list_t* GetSubNodeHandles(const node_t* const node) {
////////////////////////////////////////////////////////////////////////////////
static node_t* InsertSubNode(index_t* const idx, node_t* const node,
const uint32_t position, const node_char_t key) {
uint32_t position, const node_char_t key) {
node_t** followerNodes;
node_char_t* followerKeys;
node_t* subNode;

View File

@ -116,7 +116,7 @@ static inline uint32_t GetNumEntries(const TRI_fulltext_list_t* const list) {
////////////////////////////////////////////////////////////////////////////////
static inline void SetNumEntries(TRI_fulltext_list_t* const list,
const uint32_t value) {
uint32_t value) {
uint32_t* head = (uint32_t*)list;
*(++head) = value;
@ -168,7 +168,7 @@ static void SortList(TRI_fulltext_list_t* list) {
/// @brief get the memory usage for a list of the specified size
////////////////////////////////////////////////////////////////////////////////
static inline size_t MemoryList(const uint32_t size) {
static inline size_t MemoryList(uint32_t size) {
return sizeof(uint32_t) + // numAllocated
sizeof(uint32_t) + // numEntries
size * sizeof(TRI_fulltext_list_entry_t); // entries
@ -179,7 +179,7 @@ static inline size_t MemoryList(const uint32_t size) {
////////////////////////////////////////////////////////////////////////////////
static TRI_fulltext_list_t* IncreaseList(TRI_fulltext_list_t* list,
const uint32_t size) {
uint32_t size) {
TRI_fulltext_list_t* copy =
TRI_Reallocate(TRI_UNKNOWN_MEM_ZONE, list, MemoryList(size));
@ -222,7 +222,7 @@ TRI_fulltext_list_t* TRI_CloneListFulltextIndex(
/// @brief create a new list
////////////////////////////////////////////////////////////////////////////////
TRI_fulltext_list_t* TRI_CreateListFulltextIndex(const uint32_t size) {
TRI_fulltext_list_t* TRI_CreateListFulltextIndex(uint32_t size) {
TRI_fulltext_list_t* list =
TRI_Allocate(TRI_UNKNOWN_MEM_ZONE, MemoryList(size), false);

View File

@ -167,9 +167,6 @@ bool ApplicationEndpointServer::buildServers() {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationEndpointServer::setupOptions(
std::map<std::string, ProgramOptionsDescription>& options) {
@ -205,9 +202,6 @@ void ApplicationEndpointServer::setupOptions(
"SSL cipher list, see OpenSSL documentation");
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationEndpointServer::afterOptionParsing(ProgramOptions& options) {
// create the ssl context (if possible)
@ -343,9 +337,6 @@ std::vector<std::string> const& ApplicationEndpointServer::getEndpointMapping(
return _endpointList.getMapping(endpoint);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationEndpointServer::prepare() {
if (_disabled) {
@ -372,9 +363,6 @@ bool ApplicationEndpointServer::prepare() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationEndpointServer::open() {
if (_disabled) {
@ -388,9 +376,6 @@ bool ApplicationEndpointServer::open() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationEndpointServer::close() {
if (_disabled) {
@ -403,9 +388,6 @@ void ApplicationEndpointServer::close() {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationEndpointServer::stop() {
if (_disabled) {

View File

@ -83,15 +83,9 @@ class ApplicationEndpointServer : public ApplicationFeature {
void setBasePath(std::string const& basePath) { _basePath = basePath; }
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void setupOptions(std::map<std::string, basics::ProgramOptionsDescription>&);
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool afterOptionParsing(basics::ProgramOptions&);
@ -113,27 +107,15 @@ class ApplicationEndpointServer : public ApplicationFeature {
std::vector<std::string> const& getEndpointMapping(std::string const&);
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool prepare();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool open();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void close();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void stop();

View File

@ -952,9 +952,6 @@ int32_t HttpCommTask::getCompatibility() const {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool HttpCommTask::setup(Scheduler* scheduler, EventLoop loop) {
bool ok = SocketTask::setup(scheduler, loop);
@ -971,15 +968,9 @@ bool HttpCommTask::setup(Scheduler* scheduler, EventLoop loop) {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void HttpCommTask::cleanup() { SocketTask::cleanup(); }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool HttpCommTask::handleEvent(EventToken token, EventType events) {
bool result = SocketTask::handleEvent(token, events);
@ -991,9 +982,6 @@ bool HttpCommTask::handleEvent(EventToken token, EventType events) {
return result;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void HttpCommTask::signalTask(TaskData* data) {
// data response
@ -1029,9 +1017,6 @@ void HttpCommTask::signalTask(TaskData* data) {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool HttpCommTask::handleRead() {
bool res = true;
@ -1066,9 +1051,6 @@ bool HttpCommTask::handleRead() {
return res;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void HttpCommTask::completedWriteBuffer() {
_writeBuffer = nullptr;
@ -1090,9 +1072,6 @@ void HttpCommTask::completedWriteBuffer() {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void HttpCommTask::handleTimeout() {
_clientClosed = true;

View File

@ -161,47 +161,26 @@ class HttpCommTask : public SocketTask, public RequestStatisticsAgent {
protected:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool setup(Scheduler* scheduler, EventLoop loop) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void cleanup() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool handleEvent(EventToken token, EventType events) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void signalTask(TaskData*) override;
protected:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool handleRead() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void completedWriteBuffer() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void handleTimeout() override;

View File

@ -38,9 +38,6 @@ HttpListenTask::HttpListenTask(HttpServer* server, Endpoint* endpoint)
: Task("HttpListenTask"), ListenTask(endpoint), _server(server) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool HttpListenTask::handleConnected(TRI_socket_t s,
const ConnectionInfo& info) {

View File

@ -51,9 +51,6 @@ class HttpListenTask : public ListenTask {
protected:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool handleConnected(TRI_socket_t s, ConnectionInfo const& info);

View File

@ -60,15 +60,9 @@ HttpServerJob::~HttpServerJob() {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
size_t HttpServerJob::queue() const { return _handler->queue(); }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void HttpServerJob::work() {
TRI_ASSERT(_handler.get() != nullptr);
@ -109,24 +103,15 @@ void HttpServerJob::work() {
_workDesc = WorkMonitor::popHandler(_handler.release(), false);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool HttpServerJob::cancel() { return _handler->cancel(); }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void HttpServerJob::cleanup(DispatcherQueue* queue) {
queue->removeJob(this);
delete this;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void HttpServerJob::handleError(triagens::basics::Exception const& ex) {
_handler->handleError(ex);

View File

@ -69,33 +69,18 @@ class HttpServerJob : public Job {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
size_t queue() const override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void work() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool cancel() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void cleanup(DispatcherQueue*) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void handleError(basics::Exception const&) override;

View File

@ -69,9 +69,6 @@ HttpsCommTask::~HttpsCommTask() {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool HttpsCommTask::setup(Scheduler* scheduler, EventLoop loop) {
// setup base class
@ -111,9 +108,6 @@ bool HttpsCommTask::setup(Scheduler* scheduler, EventLoop loop) {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool HttpsCommTask::handleEvent(EventToken token, EventType revents) {
// try to accept the SSL connection
@ -165,9 +159,6 @@ bool HttpsCommTask::handleEvent(EventToken token, EventType revents) {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool HttpsCommTask::fillReadBuffer() {
if (nullptr == _ssl) {
@ -183,9 +174,6 @@ bool HttpsCommTask::fillReadBuffer() {
return trySSLRead();
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool HttpsCommTask::handleWrite() {
if (nullptr == _ssl) {

View File

@ -69,28 +69,16 @@ class HttpsCommTask : public HttpCommTask {
protected:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool setup(Scheduler*, EventLoop) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool handleEvent(EventToken, EventType) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool fillReadBuffer() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool handleWrite() override;

View File

@ -65,9 +65,6 @@ void HttpsServer::setVerificationCallback(int (*func)(int, X509_STORE_CTX*)) {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpCommTask* HttpsServer::createCommTask(TRI_socket_t s,
const ConnectionInfo& info) {

View File

@ -65,23 +65,14 @@ class HttpsServer : public HttpServer {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
char const* protocol() const override { return "https"; }
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
Endpoint::EncryptionType encryptionType() const override {
return Endpoint::ENCRYPTION_SSL;
}
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
HttpCommTask* createCommTask(TRI_socket_t, const ConnectionInfo&) override;

View File

@ -78,21 +78,12 @@ class PathHandler : public HttpHandler {
PathHandler(HttpRequest* request, Options const* options);
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override { return true; }
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void handleError(const basics::Exception&) override;

View File

@ -62,9 +62,6 @@ RestAdminLogHandler::RestAdminLogHandler(rest::HttpRequest* request)
: RestBaseHandler(request) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestAdminLogHandler::isDirect() const { return true; }

View File

@ -43,9 +43,6 @@ class RestAdminLogHandler : public RestBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override;

View File

@ -43,9 +43,6 @@ using namespace triagens::admin;
RestBaseHandler::RestBaseHandler(HttpRequest* request) : HttpHandler(request) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void RestBaseHandler::handleError(Exception const& ex) {
generateError(HttpResponse::responseCode(ex.code()), ex.code(), ex.what());

View File

@ -48,9 +48,6 @@ class RestBaseHandler : public rest::HttpHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void handleError(basics::Exception const&);

View File

@ -80,9 +80,6 @@ class RestBatchHandler : public RestVocbaseBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t execute();

View File

@ -53,9 +53,6 @@ RestCursorHandler::RestCursorHandler(
_queryKilled(false) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestCursorHandler::execute() {
// extract the sub-request type
@ -81,9 +78,6 @@ HttpHandler::status_t RestCursorHandler::execute() {
return status_t(HANDLER_DONE);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestCursorHandler::cancel() { return cancelQuery(); }

View File

@ -58,15 +58,9 @@ class RestCursorHandler : public RestVocbaseBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
virtual status_t execute() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool cancel() override;

View File

@ -43,15 +43,9 @@ extern AnyServer* ArangoInstance;
RestDebugHandler::RestDebugHandler(HttpRequest* request)
: RestVocbaseBaseHandler(request) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestDebugHandler::isDirect() const { return false; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestDebugHandler::execute() {
// extract the sub-request type

View File

@ -38,15 +38,9 @@ class RestDebugHandler : public triagens::arango::RestVocbaseBaseHandler {
explicit RestDebugHandler(triagens::rest::HttpRequest*);
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override;
};

View File

@ -41,9 +41,6 @@ RestDebugHelperHandler::RestDebugHelperHandler(HttpRequest* request)
: RestBaseHandler(request) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestDebugHelperHandler::isDirect() const { return false; }

View File

@ -44,9 +44,6 @@ class RestDebugHelperHandler : public RestBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override;

View File

@ -46,9 +46,6 @@ RestDocumentHandler::RestDocumentHandler(HttpRequest* request)
: RestVocbaseBaseHandler(request) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestDocumentHandler::execute() {
// extract the sub-request type

View File

@ -44,9 +44,6 @@ class RestDocumentHandler : public RestVocbaseBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override final;

View File

@ -38,9 +38,6 @@ RestEdgesHandler::RestEdgesHandler(HttpRequest* request)
: RestVocbaseBaseHandler(request) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestEdgesHandler::execute() {
// extract the sub-request type

View File

@ -45,9 +45,6 @@ class RestEdgesHandler : public RestVocbaseBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override final;

View File

@ -47,9 +47,6 @@ RestExportHandler::RestExportHandler(HttpRequest* request)
: RestVocbaseBaseHandler(request), _restrictions() {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestExportHandler::execute() {
if (ServerState::instance()->isCoordinator()) {

View File

@ -46,9 +46,6 @@ class RestExportHandler : public RestVocbaseBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override;

View File

@ -47,9 +47,6 @@ RestImportHandler::RestImportHandler(HttpRequest* request)
: RestVocbaseBaseHandler(request), _onDuplicateAction(DUPLICATE_ERROR) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestImportHandler::execute() {
if (ServerState::instance()->isCoordinator()) {

View File

@ -70,9 +70,6 @@ class RestImportHandler : public RestVocbaseBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override final;

View File

@ -45,15 +45,9 @@ RestJobHandler::RestJobHandler(HttpRequest* request,
_jobManager(data->second) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestJobHandler::isDirect() const { return true; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestJobHandler::execute() {
// extract the sub-request type

View File

@ -50,9 +50,6 @@ class RestJobHandler : public RestBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override;

View File

@ -34,15 +34,9 @@ RestPleaseUpgradeHandler::RestPleaseUpgradeHandler(HttpRequest* request)
: HttpHandler(request) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestPleaseUpgradeHandler::isDirect() const { return true; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestPleaseUpgradeHandler::execute() {
createResponse(HttpResponse::OK);
@ -62,9 +56,6 @@ HttpHandler::status_t RestPleaseUpgradeHandler::execute() {
return status_t(HANDLER_DONE);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void RestPleaseUpgradeHandler::handleError(const Exception&) {}

View File

@ -44,21 +44,12 @@ class RestPleaseUpgradeHandler : public rest::HttpHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void handleError(const basics::Exception&) override;
};

View File

@ -38,15 +38,9 @@ RestQueryCacheHandler::RestQueryCacheHandler(HttpRequest* request)
: RestVocbaseBaseHandler(request) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestQueryCacheHandler::isDirect() const { return false; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestQueryCacheHandler::execute() {
// extract the sub-request type

View File

@ -43,15 +43,9 @@ class RestQueryCacheHandler : public RestVocbaseBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override;

View File

@ -52,17 +52,11 @@ RestQueryHandler::RestQueryHandler(HttpRequest* request,
: RestVocbaseBaseHandler(request), _applicationV8(applicationV8) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestQueryHandler::isDirect() const {
return _request->requestType() != HttpRequest::HTTP_REQUEST_POST;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestQueryHandler::execute() {
// extract the sub-request type

View File

@ -46,15 +46,9 @@ class RestQueryHandler : public RestVocbaseBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override;

View File

@ -71,9 +71,6 @@ RestReplicationHandler::RestReplicationHandler(HttpRequest* request)
RestReplicationHandler::~RestReplicationHandler() {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestReplicationHandler::execute() {
// extract the request type

View File

@ -56,9 +56,6 @@ class RestReplicationHandler : public RestVocbaseBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t execute();

View File

@ -38,9 +38,6 @@ RestShutdownHandler::RestShutdownHandler(triagens::rest::HttpRequest* request,
static_cast<triagens::rest::ApplicationServer*>(applicationServer)) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestShutdownHandler::isDirect() const { return true; }

View File

@ -45,9 +45,6 @@ class RestShutdownHandler : public RestBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override;

View File

@ -53,9 +53,6 @@ RestSimpleHandler::RestSimpleHandler(
_queryKilled(false) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestSimpleHandler::execute() {
// extract the request type
@ -101,9 +98,6 @@ HttpHandler::status_t RestSimpleHandler::execute() {
return status_t(HANDLER_DONE);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestSimpleHandler::cancel() { return cancelQuery(); }

View File

@ -53,15 +53,9 @@ class RestSimpleHandler : public RestVocbaseBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override final;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool cancel() override;

View File

@ -43,9 +43,6 @@ RestSimpleQueryHandler::RestSimpleQueryHandler(
: RestCursorHandler(request, pair) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestSimpleQueryHandler::execute() {
// extract the sub-request type

View File

@ -50,9 +50,6 @@ class RestSimpleQueryHandler : public RestCursorHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override final;

View File

@ -44,9 +44,6 @@ RestUploadHandler::RestUploadHandler(HttpRequest* request)
RestUploadHandler::~RestUploadHandler() {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestUploadHandler::execute() {
// extract the request type

View File

@ -44,9 +44,6 @@ class RestUploadHandler : public RestVocbaseBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t execute();

View File

@ -43,15 +43,9 @@ extern AnyServer* ArangoInstance;
RestVersionHandler::RestVersionHandler(HttpRequest* request)
: RestBaseHandler(request) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool RestVersionHandler::isDirect() const { return true; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
HttpHandler::status_t RestVersionHandler::execute() {
try {

View File

@ -38,15 +38,9 @@ class RestVersionHandler : public triagens::admin::RestBaseHandler {
explicit RestVersionHandler(triagens::rest::HttpRequest*);
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override;
};

View File

@ -359,9 +359,6 @@ class RestVocbaseBaseHandler : public admin::RestBaseHandler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override { return false; }

View File

@ -35,15 +35,9 @@ using triagens::rest::HttpHandler;
WorkMonitorHandler::WorkMonitorHandler(HttpRequest* request)
: RestBaseHandler(request) {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool WorkMonitorHandler::isDirect() const { return true; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
#include <iostream>

View File

@ -37,15 +37,9 @@ class WorkMonitorHandler : public triagens::admin::RestBaseHandler {
explicit WorkMonitorHandler(triagens::rest::HttpRequest*);
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool isDirect() const override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
status_t execute() override;
};

View File

@ -442,9 +442,6 @@ ArangoServer::~ArangoServer() {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ArangoServer::buildApplicationServer() {
_applicationServer =
@ -867,9 +864,6 @@ void ArangoServer::buildApplicationServer() {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
int ArangoServer::startupServer() {
TRI_InitializeStatistics();

View File

@ -79,15 +79,9 @@ class ArangoServer : public rest::AnyServer {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void buildApplicationServer();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
int startupServer();

View File

@ -361,9 +361,6 @@ void ApplicationScheduler::disableControlCHandler() {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationScheduler::setupOptions(
std::map<std::string, ProgramOptionsDescription>& options) {
@ -404,9 +401,6 @@ void ApplicationScheduler::setupOptions(
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationScheduler::afterOptionParsing(
triagens::basics::ProgramOptions& options) {
@ -423,9 +417,6 @@ bool ApplicationScheduler::afterOptionParsing(
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationScheduler::prepare() {
if (_disabled) {
@ -437,9 +428,6 @@ bool ApplicationScheduler::prepare() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationScheduler::start() {
if (_disabled) {
@ -473,9 +461,6 @@ bool ApplicationScheduler::start() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationScheduler::open() {
if (_disabled) {
@ -489,9 +474,6 @@ bool ApplicationScheduler::open() {
return false;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationScheduler::stop() {
if (_disabled) {

View File

@ -88,39 +88,21 @@ class ApplicationScheduler : public ApplicationFeature {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void setupOptions(std::map<std::string, basics::ProgramOptionsDescription>&);
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool afterOptionParsing(basics::ProgramOptions&);
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool prepare();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool start();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool open();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void stop();

View File

@ -105,15 +105,9 @@ class ListenTask : virtual public Task {
bool setup(Scheduler*, EventLoop) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void cleanup() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool handleEvent(EventToken token, EventType) override;

View File

@ -71,21 +71,12 @@ class PeriodicTask : virtual public Task {
void resetTimer(double offset, double interval);
protected:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool setup(Scheduler*, EventLoop) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void cleanup() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool handleEvent(EventToken, EventType) override;

View File

@ -298,9 +298,6 @@ SchedulerLibev::~SchedulerLibev() {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void SchedulerLibev::eventLoop(EventLoop loop) {
struct ev_loop* l = (struct ev_loop*)lookupLoop(loop);
@ -308,9 +305,6 @@ void SchedulerLibev::eventLoop(EventLoop loop) {
ev_loop(l, 0);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void SchedulerLibev::wakeupLoop(EventLoop loop) {
if (size_t(loop) >= nrThreads) {
@ -320,9 +314,6 @@ void SchedulerLibev::wakeupLoop(EventLoop loop) {
ev_async_send(((struct ev_loop**)_loops)[loop], ((ev_async**)_wakers)[loop]);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void SchedulerLibev::uninstallEvent(EventToken watcher) {
if (watcher == nullptr) {
@ -366,9 +357,6 @@ void SchedulerLibev::uninstallEvent(EventToken watcher) {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
EventToken SchedulerLibev::installPeriodicEvent(EventLoop loop, Task* task,
double offset,
@ -383,9 +371,6 @@ EventToken SchedulerLibev::installPeriodicEvent(EventLoop loop, Task* task,
return watcher;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void SchedulerLibev::rearmPeriodic(EventToken token, double offset,
double interval) {
@ -400,9 +385,6 @@ void SchedulerLibev::rearmPeriodic(EventToken token, double offset,
ev_periodic_again(watcher->loop, w);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
EventToken SchedulerLibev::installSignalEvent(EventLoop loop, Task* task,
int signal) {
@ -416,9 +398,6 @@ EventToken SchedulerLibev::installSignalEvent(EventLoop loop, Task* task,
return watcher;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
// ..........................................................................
// Windows likes to operate on SOCKET types (sort of handles) while libev
@ -451,9 +430,6 @@ EventToken SchedulerLibev::installSocketEvent(EventLoop loop, EventType type,
return watcher;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void SchedulerLibev::startSocketEvents(EventToken token) {
SocketWatcher* watcher = (SocketWatcher*)token;
@ -469,9 +445,6 @@ void SchedulerLibev::startSocketEvents(EventToken token) {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void SchedulerLibev::stopSocketEvents(EventToken token) {
SocketWatcher* watcher = (SocketWatcher*)token;
@ -487,9 +460,6 @@ void SchedulerLibev::stopSocketEvents(EventToken token) {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
EventToken SchedulerLibev::installTimerEvent(EventLoop loop, Task* task,
double timeout) {
@ -503,9 +473,6 @@ EventToken SchedulerLibev::installTimerEvent(EventLoop loop, Task* task,
return watcher;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void SchedulerLibev::clearTimer(EventToken token) {
TimerWatcher* watcher = (TimerWatcher*)token;
@ -518,9 +485,6 @@ void SchedulerLibev::clearTimer(EventToken token) {
ev_timer_stop(watcher->loop, w);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void SchedulerLibev::rearmTimer(EventToken token, double timeout) {
TimerWatcher* watcher = (TimerWatcher*)token;
@ -534,9 +498,6 @@ void SchedulerLibev::rearmTimer(EventToken token, double timeout) {
ev_timer_again(watcher->loop, w);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void SchedulerLibev::signalTask(std::unique_ptr<TaskData>& data) {
size_t loop = size_t(data->_loop);

View File

@ -73,83 +73,44 @@ class SchedulerLibev : public Scheduler {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void eventLoop(EventLoop) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void wakeupLoop(EventLoop) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
EventToken installSocketEvent(EventLoop, EventType, Task*,
TRI_socket_t) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void startSocketEvents(EventToken) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void stopSocketEvents(EventToken) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
EventToken installTimerEvent(EventLoop, Task*, double timeout) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void clearTimer(EventToken) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void rearmTimer(EventToken, double timeout) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
EventToken installPeriodicEvent(EventLoop, Task*, double offset,
double interval) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void rearmPeriodic(EventToken, double offset, double timeout) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
EventToken installSignalEvent(EventLoop, Task*, int signal) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void uninstallEvent(EventToken) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void signalTask(std::unique_ptr<TaskData>&) override;

View File

@ -211,9 +211,6 @@ void SchedulerThread::signalTask(std::unique_ptr<TaskData>& data) {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void SchedulerThread::run() {
LOG_TRACE("scheduler thread started (%llu)", (unsigned long long)threadId());
@ -359,9 +356,6 @@ void SchedulerThread::run() {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void SchedulerThread::addStatus(VPackBuilder* b) {
Thread::addStatus(b);

View File

@ -108,15 +108,9 @@ class SchedulerThread : public basics::Thread, private TaskManager {
protected:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void run();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void addStatus(arangodb::velocypack::Builder* b);

View File

@ -79,27 +79,15 @@ class SignalTask : virtual public Task {
~SignalTask();
protected:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool setup(Scheduler*, EventLoop) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void cleanup() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool handleEvent(EventToken, EventType) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool needsMainEventLoop() const override;

View File

@ -84,9 +84,6 @@ SocketTask::~SocketTask() {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void SocketTask::setKeepAliveTimeout(double timeout) {
if (_keepAliveWatcher != nullptr && timeout > 0.0) {
@ -273,9 +270,6 @@ void SocketTask::setWriteBuffer(StringBuffer* buffer,
bool SocketTask::hasWriteBuffer() const { return _writeBuffer != nullptr; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool SocketTask::setup(Scheduler* scheduler, EventLoop loop) {
#ifdef _WIN32
@ -364,9 +358,6 @@ void SocketTask::cleanup() {
_writeWatcher = nullptr;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool SocketTask::handleEvent(EventToken token, EventType revents) {
bool result = true;

View File

@ -140,9 +140,6 @@ class SocketTask : virtual public Task, public ConnectionStatisticsAgent {
protected:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool setup(Scheduler*, EventLoop) override;
@ -152,9 +149,6 @@ class SocketTask : virtual public Task, public ConnectionStatisticsAgent {
void cleanup() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool handleEvent(EventToken token, EventType) override;

View File

@ -64,21 +64,12 @@ class TimerTask : virtual public Task {
~TimerTask();
protected:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool setup(Scheduler*, EventLoop) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void cleanup() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool handleEvent(EventToken token, EventType event) override;

View File

@ -914,9 +914,6 @@ void ApplicationV8::prepareServer() {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationV8::setupOptions(
std::map<std::string, basics::ProgramOptionsDescription>& options) {
@ -947,9 +944,6 @@ void ApplicationV8::setupOptions(
"one or more directories separated by semi-colons (deprecated)");
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationV8::prepare() {
// check the startup path
@ -1006,9 +1000,6 @@ bool ApplicationV8::prepare() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationV8::prepare2() {
size_t nrInstances = _nrInstances;
@ -1040,9 +1031,6 @@ bool ApplicationV8::prepare2() {
return _ok;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool ApplicationV8::start() {
TRI_ASSERT(_gcThread == nullptr);
@ -1053,9 +1041,6 @@ bool ApplicationV8::start() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationV8::close() {
_stopping = true;
@ -1082,9 +1067,6 @@ void ApplicationV8::close() {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void ApplicationV8::stop() {
// send all busy contexts a termate signal

View File

@ -358,39 +358,21 @@ class ApplicationV8 : public rest::ApplicationFeature {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void setupOptions(std::map<std::string, basics::ProgramOptionsDescription>&);
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool prepare();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool prepare2();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool start();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void close();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void stop();

View File

@ -68,9 +68,6 @@ V8Job::~V8Job() {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void V8Job::work() {
if (_canceled) {
@ -145,27 +142,18 @@ void V8Job::work() {
_v8Dealer->exitContext(context);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool V8Job::cancel() {
_canceled = true;
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void V8Job::cleanup(DispatcherQueue* queue) {
queue->removeJob(this);
delete this;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void V8Job::handleError(Exception const& ex) {}

View File

@ -57,33 +57,18 @@ class V8Job : public rest::Job {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void work() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool cancel() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void cleanup(rest::DispatcherQueue*) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void handleError(basics::Exception const& ex) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
virtual std::string const& getName() const override { return _command; }

View File

@ -67,15 +67,9 @@ V8QueueJob::~V8QueueJob() {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
size_t V8QueueJob::queue() const { return _queue; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void V8QueueJob::work() {
if (_canceled) {
@ -141,27 +135,18 @@ void V8QueueJob::work() {
_v8Dealer->exitContext(context);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool V8QueueJob::cancel() {
_canceled = true;
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void V8QueueJob::cleanup(DispatcherQueue* queue) {
queue->removeJob(this);
delete this;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void V8QueueJob::handleError(Exception const& ex) {}

View File

@ -54,33 +54,18 @@ class V8QueueJob : public rest::Job {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
size_t queue() const override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void work() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool cancel() override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void cleanup(rest::DispatcherQueue*) override;
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void handleError(basics::Exception const& ex) override;

View File

@ -94,9 +94,6 @@ class v8_action_t : public TRI_action_t {
_callbacks[isolate].Reset(isolate, callback);
}
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
TRI_action_result_t execute(TRI_vocbase_t* vocbase, HttpRequest* request,
Mutex* dataLock, void** data) {
@ -184,9 +181,6 @@ class v8_action_t : public TRI_action_t {
return result;
}
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool cancel(Mutex* dataLock, void** data) {
{

View File

@ -227,7 +227,7 @@ static void JS_SynchronizeReplication(
v8::Handle<v8::Array> a = v8::Handle<v8::Array>::Cast(
object->Get(TRI_V8_ASCII_STRING("restrictCollections")));
const uint32_t n = a->Length();
uint32_t const n = a->Length();
for (uint32_t i = 0; i < n; ++i) {
v8::Handle<v8::Value> cname = a->Get(i);

View File

@ -202,9 +202,6 @@ void LogfileManager::initialize(std::string* path, TRI_server_t* server) {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void LogfileManager::setupOptions(std::map<
std::string, triagens::basics::ProgramOptionsDescription>& options) {
@ -237,9 +234,6 @@ void LogfileManager::setupOptions(std::map<
"maximum wait time per operation when write-throttled (in milliseconds)");
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool LogfileManager::prepare() {
static bool Prepared = false;
@ -331,9 +325,6 @@ bool LogfileManager::prepare() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool LogfileManager::start() {
static bool started = false;
@ -388,9 +379,6 @@ bool LogfileManager::start() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
bool LogfileManager::open() {
static bool opened = false;
@ -527,15 +515,9 @@ bool LogfileManager::open() {
return true;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void LogfileManager::close() {}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void LogfileManager::stop() {
if (!_startCalled) {

View File

@ -111,40 +111,22 @@ class LogfileManager : public rest::ApplicationFeature {
public:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void setupOptions(
std::map<std::string, triagens::basics::ProgramOptionsDescription>&);
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool prepare();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool open();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
bool start();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void close();
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void stop();

View File

@ -129,7 +129,7 @@ inline bool isBase64U(unsigned char c) {
}
bool parseHexanumber(char const* inputStr, size_t len, uint32_t* outputInt) {
const uint32_t charVal[16] = {0, 1, 2, 3, 4, 5, 6, 7,
uint32_t const charVal[16] = {0, 1, 2, 3, 4, 5, 6, 7,
8, 9, 10, 11, 12, 13, 14, 15};
bool ok = true;
for (size_t j = 0; j < len; j++) {

View File

@ -335,13 +335,10 @@ void WorkMonitor::requestWorkOverview(uint64_t taskId) {
WORK_OVERVIEW.push(taskId);
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void WorkMonitor::run() {
const uint32_t maxSleep = 100 * 1000;
const uint32_t minSleep = 100;
uint32_t const maxSleep = 100 * 1000;
uint32_t const minSleep = 100;
uint32_t s = minSleep;
// clean old entries and create summary if requested

View File

@ -171,9 +171,6 @@ class WorkMonitor : public triagens::basics::Thread {
static void SEND_WORK_OVERVIEW(uint64_t, std::string const&);
protected:
//////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
//////////////////////////////////////////////////////////////////////////////
void run() override;

View File

@ -117,15 +117,9 @@ HttpRequest::~HttpRequest() {
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
char const* HttpRequest::requestPath() const { return _requestPath; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
void HttpRequest::write(TRI_string_buffer_t* buffer) const {
std::string&& method = translateMethod(_type);
@ -221,15 +215,9 @@ void HttpRequest::write(TRI_string_buffer_t* buffer) const {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
int64_t HttpRequest::contentLength() const { return _contentLength; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
char const* HttpRequest::header(char const* key) const {
Dictionary<char const*>::KeyValue const* kv = _headers.lookup(key);
@ -241,9 +229,6 @@ char const* HttpRequest::header(char const* key) const {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
char const* HttpRequest::header(char const* key, bool& found) const {
Dictionary<char const*>::KeyValue const* kv = _headers.lookup(key);
@ -257,9 +242,6 @@ char const* HttpRequest::header(char const* key, bool& found) const {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
std::map<std::string, std::string> HttpRequest::headers() const {
basics::Dictionary<char const*>::KeyValue const* begin;
@ -282,9 +264,6 @@ std::map<std::string, std::string> HttpRequest::headers() const {
return result;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
char const* HttpRequest::value(char const* key) const {
Dictionary<char const*>::KeyValue const* kv = _values.lookup(key);
@ -296,9 +275,6 @@ char const* HttpRequest::value(char const* key) const {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
char const* HttpRequest::value(char const* key, bool& found) const {
Dictionary<char const*>::KeyValue const* kv = _values.lookup(key);
@ -312,9 +288,6 @@ char const* HttpRequest::value(char const* key, bool& found) const {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
std::map<std::string, std::string> HttpRequest::values() const {
basics::Dictionary<char const*>::KeyValue const* begin;
@ -335,9 +308,6 @@ std::map<std::string, std::string> HttpRequest::values() const {
return result;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
std::map<std::string, std::vector<char const*>*> HttpRequest::arrayValues() const {
basics::Dictionary<std::vector<char const*>*>::KeyValue const* begin;
@ -358,9 +328,6 @@ std::map<std::string, std::vector<char const*>*> HttpRequest::arrayValues() cons
return result;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
char const* HttpRequest::cookieValue(char const* key) const {
Dictionary<char const*>::KeyValue const* kv = _cookies.lookup(key);
@ -372,9 +339,6 @@ char const* HttpRequest::cookieValue(char const* key) const {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
char const* HttpRequest::cookieValue(char const* key, bool& found) const {
Dictionary<char const*>::KeyValue const* kv = _cookies.lookup(key);
@ -388,9 +352,6 @@ char const* HttpRequest::cookieValue(char const* key, bool& found) const {
}
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
std::map<std::string, std::string> HttpRequest::cookieValues() const {
basics::Dictionary<char const*>::KeyValue const* begin;
@ -411,23 +372,14 @@ std::map<std::string, std::string> HttpRequest::cookieValues() const {
return result;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
char const* HttpRequest::body() const {
return _body == nullptr ? EMPTY_STR : _body;
}
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
size_t HttpRequest::bodySize() const { return _bodySize; }
////////////////////////////////////////////////////////////////////////////////
/// {@inheritDoc}
////////////////////////////////////////////////////////////////////////////////
int HttpRequest::setBody(char const* newBody, size_t length) {
_body = TRI_DuplicateString2Z(TRI_UNKNOWN_MEM_ZONE, newBody, length);

Some files were not shown because too many files have changed in this diff Show More