Added: Task manager dump commands to pipeline service.

--HG--
branch : build_pipeline_v3
hg/feature/build_pipeline_v3
kaetemi 13 years ago
parent e9ac3fbdd9
commit 90cc3bda2c

@ -318,13 +318,15 @@ public:
}
bool done = false;
if (!CallbackCalled)
if (!CallbackCalled && Ready)
{
done = true;
CallbackCalled = true;
}
Mutex.leave();
nlassert(FilesUpdated == FilesRequested);
if (done) doneRemove();
}

@ -405,7 +405,7 @@ NLMISC_COMMAND(reloadSheets, "Reload all sheets.", "")
if(args.size() != 0) return false;
if (!PIPELINE::reloadSheets())
{
nlinfo("I'm afraid I cannot do this, my friend.");
log.displayNL("I'm afraid I cannot do this, my friend.");
return false;
}
return true;
@ -416,12 +416,32 @@ NLMISC_COMMAND(updateDatabaseStatus, "Updates the entire database status. This a
if(args.size() != 0) return false;
if (!PIPELINE::updateDatabaseStatus())
{
nlinfo("I'm afraid I cannot do this, my friend.");
log.displayNL("I'm afraid I cannot do this, my friend.");
return false;
}
return true;
}
NLMISC_COMMAND(dumpTaskManager, "Dumps the task manager.", "")
{
if(args.size() != 0) return false;
std::vector<std::string> output;
PIPELINE::s_TaskManager->dump(output);
for (std::vector<std::string>::iterator it = output.begin(), end = output.end(); it != end; ++it)
log.displayNL("DUMP: %s", (*it).c_str());
return true;
}
NLMISC_COMMAND(dumpAsyncFileManager, "Dumps the async file manager.", "")
{
if(args.size() != 0) return false;
std::vector<std::string> output;
NLMISC::CAsyncFileManager::getInstance().dump(output);
for (std::vector<std::string>::iterator it = output.begin(), end = output.end(); it != end; ++it)
log.displayNL("DUMP: %s", (*it).c_str());
return true;
}
NLNET_SERVICE_MAIN(PIPELINE::CPipelineService, PIPELINE_SHORT_SERVICE_NAME, PIPELINE_LONG_SERVICE_NAME, 0, PIPELINE::s_ShardCallbacks, PIPELINE_SERVICE_DIRECTORY, PIPELINE_SERVICE_DIRECTORY)
/* end of file */

Loading…
Cancel
Save