Adds immediate migration results in progress
This commit is contained in:
2102 files changed
+17482
-15071
No files matched your search
@@ -21,15 +21,14 @@
|
||||
|
||||
namespace FileManagement
|
||||
{
|
||||
MainHandler::MainHandler(QObject *parent)
|
||||
: QObject(parent)
|
||||
MainHandler::MainHandler(QObject *parent) : QObject(parent)
|
||||
, m_ddsHandler(nullptr)
|
||||
, m_dbHandler(nullptr)
|
||||
, m_handlerFileTypeInfo(nullptr)
|
||||
, m_handlerFolder(nullptr)
|
||||
, m_handlerFileContent(nullptr)
|
||||
, m_handlerWebSocket(nullptr)
|
||||
{}
|
||||
, m_handlerWebSocket(nullptr),
|
||||
m_logger(NGL::NGLLoggerBootstrap::getLogger()) {}
|
||||
|
||||
MainHandler::~MainHandler()
|
||||
{
|
||||
@@ -48,29 +47,29 @@ bool MainHandler::init(int domainId)
|
||||
m_dbHandler = std::make_shared<DbHandler>();
|
||||
if (!m_dbHandler->init(0, Settings::settings()))
|
||||
{
|
||||
ERROR_LOG() << "Initialisation dbHandler failed.";
|
||||
ERROR_LOG(m_logger) << "Initialisation dbHandler failed.";
|
||||
return false;
|
||||
}
|
||||
DEBUG_LOG() << "Initialisation dbHandler succesful.";
|
||||
DEBUG_LOG(m_logger) << "Initialisation dbHandler succesful.";
|
||||
|
||||
// initialize DDS
|
||||
m_ddsHandler.reset(new DdsHandler(domainId));
|
||||
if (!m_ddsHandler->init())
|
||||
{
|
||||
ERROR_LOG() << "Initialisation ddsHandler failed.";
|
||||
ERROR_LOG(m_logger) << "Initialisation ddsHandler failed.";
|
||||
return false;
|
||||
}
|
||||
DEBUG_LOG() << "Initialisation ddsHandler succesful.";
|
||||
DEBUG_LOG(m_logger) << "Initialisation ddsHandler succesful.";
|
||||
|
||||
// read project specific data from database
|
||||
// publish project specific data
|
||||
// initialize all handlers
|
||||
if (!initFlmHandler())
|
||||
{
|
||||
ERROR_LOG() << "Initialisation FlmHandler failed.";
|
||||
ERROR_LOG(m_logger) << "Initialisation FlmHandler failed.";
|
||||
return false;
|
||||
}
|
||||
DEBUG_LOG() << "Initialisation FlmHandler succesful.";
|
||||
DEBUG_LOG(m_logger) << "Initialisation FlmHandler succesful.";
|
||||
|
||||
m_ddsHandler->pacemaker()->setNewState(Core::RunningState::Running);
|
||||
|
||||
@@ -86,52 +85,52 @@ int MainHandler::exerciseId() const
|
||||
|
||||
bool MainHandler::initFlmHandler()
|
||||
{
|
||||
DEBUG_LOG() << "Start Initialisation FlmHandler";
|
||||
DEBUG_LOG(m_logger) << "Start Initialisation FlmHandler";
|
||||
|
||||
// FileTypeInfo
|
||||
m_handlerFileTypeInfo.reset(new HandlerFileTypeInfo(this));
|
||||
DEBUG_LOG() << "Reset HandlerFileTypeInfo successful.";
|
||||
DEBUG_LOG(m_logger) << "Reset HandlerFileTypeInfo successful.";
|
||||
|
||||
if (!m_handlerFileTypeInfo->init())
|
||||
{
|
||||
ERROR_LOG() << "Initialisation of HandlerFileTypeInfo failed.";
|
||||
ERROR_LOG(m_logger) << "Initialisation of HandlerFileTypeInfo failed.";
|
||||
return false;
|
||||
}
|
||||
DEBUG_LOG() << "Initialisation HandlerFileTypeInfo succesful.";
|
||||
DEBUG_LOG(m_logger) << "Initialisation HandlerFileTypeInfo succesful.";
|
||||
|
||||
// Folder
|
||||
m_handlerFolder.reset(new HandlerFolder(this));
|
||||
DEBUG_LOG() << "Reset HandlerFolder successful.";
|
||||
DEBUG_LOG(m_logger) << "Reset HandlerFolder successful.";
|
||||
|
||||
if (!m_handlerFolder->init())
|
||||
{
|
||||
ERROR_LOG() << "Initialisation of HandlerFolder failed.";
|
||||
ERROR_LOG(m_logger) << "Initialisation of HandlerFolder failed.";
|
||||
return false;
|
||||
}
|
||||
DEBUG_LOG() << "Initialisation HandlerFolder successful.";
|
||||
DEBUG_LOG(m_logger) << "Initialisation HandlerFolder successful.";
|
||||
|
||||
// FileContent
|
||||
m_handlerFileContent.reset(new HandlerFileContent(this));
|
||||
DEBUG_LOG() << "Reset HandlerFileContent successful.";
|
||||
DEBUG_LOG(m_logger) << "Reset HandlerFileContent successful.";
|
||||
|
||||
if (!m_handlerFileContent->init())
|
||||
{
|
||||
ERROR_LOG() << "Initialisation of HandlerFileContent failed.";
|
||||
ERROR_LOG(m_logger) << "Initialisation of HandlerFileContent failed.";
|
||||
return false;
|
||||
}
|
||||
DEBUG_LOG() << "Initialisation HandlerFileContent successful.";
|
||||
DEBUG_LOG(m_logger) << "Initialisation HandlerFileContent successful.";
|
||||
|
||||
// WebSocketServer
|
||||
m_handlerWebSocket = std::make_shared<WebSocketInterface::WebSocketInterfaceHandler>(this);
|
||||
DEBUG_LOG() << "Reset WebSocketInterfaceHandler successful.";
|
||||
DEBUG_LOG(m_logger) << "Reset WebSocketInterfaceHandler successful.";
|
||||
|
||||
if (!m_handlerWebSocket->init())
|
||||
{
|
||||
ERROR_LOG() << "Initialisation WebSocketInterfaceHandler failed.";
|
||||
ERROR_LOG(m_logger) << "Initialisation WebSocketInterfaceHandler failed.";
|
||||
return false;
|
||||
}
|
||||
m_ddsHandler->pacemaker()->addPort(m_handlerWebSocket->serverWebSocketPort(), Core::PortType::WebSocketServer);
|
||||
DEBUG_LOG() << "Initialisation WebSocketInterfaceHandler successful.";
|
||||
DEBUG_LOG(m_logger) << "Initialisation WebSocketInterfaceHandler successful.";
|
||||
|
||||
|
||||
|
||||
@@ -139,7 +138,7 @@ bool MainHandler::initFlmHandler()
|
||||
|
||||
|
||||
m_thpScriptServer.reset(new ThpScriptServer(this));
|
||||
DEBUG_LOG() << "Initialisation ThpTcpScriptServer successful.";
|
||||
DEBUG_LOG(m_logger) << "Initialisation ThpTcpScriptServer successful.";
|
||||
|
||||
|
||||
|
||||
@@ -149,10 +148,10 @@ bool MainHandler::initFlmHandler()
|
||||
m_pdfServer.reset(new PdfServer(this, this));
|
||||
if (!m_pdfServer->init())
|
||||
{
|
||||
ERROR_LOG() << "Initialisation PdfServer failed.";
|
||||
ERROR_LOG(m_logger) << "Initialisation PdfServer failed.";
|
||||
return false;
|
||||
}
|
||||
DEBUG_LOG() << "Initialisation PdfServer successful.";
|
||||
DEBUG_LOG(m_logger) << "Initialisation PdfServer successful.";
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user