Adds immediate migration results in progress

This commit is contained in:
torsten committed 2026-08-19 11:18:24 +02:00
1 parent 8453e104c5
commit 3bb6e89496
2102 files changed
+17482 -15071

No files matched your search

@@ -19,7 +19,7 @@ ForeignInterfaceImpl::ForeignInterfaceImpl(const std::shared_ptr<ParticipantMana
{
if (!m_ppmDtc)
{
WARNING_LOG() << "m_ppmDtc not available, No color and injury information will be included in created symbols";
WARNING_LOG(m_logger) << "m_ppmDtc not available, No color and injury information will be included in created symbols";
Q_ASSERT(false);
}
}
@@ -97,7 +97,7 @@ QSharedPointer<SymbolResult> ForeignInterfaceImpl::findImage(const ParticipantMa
{
if (!m_aesDtc)
{
WARNING_LOG() << "Fetching 'm_aesDtc' failed, No color and injury information will be included in symbol created for participant.id() " << participant.id();
WARNING_LOG(m_logger) << "Fetching 'm_aesDtc' failed, No color and injury information will be included in symbol created for participant.id() " << participant.id();
return findImage(symDataToRender);
}
const int partyId = m_aesDtc->partyForDusMine(lastState.originatorId());
@@ -110,7 +110,7 @@ QSharedPointer<SymbolResult> ForeignInterfaceImpl::findImage(const ParticipantMa
{
if (!m_aesDtc)
{
WARNING_LOG() << "Fetching 'm_aesDtc' failed, No color and injury information will be included in symbol created for participant.id() " << participant.id();
WARNING_LOG(m_logger) << "Fetching 'm_aesDtc' failed, No color and injury information will be included in symbol created for participant.id() " << participant.id();
return findImage(symDataToRender);
}
@@ -52,6 +52,8 @@ public:
AdvancedSymbology::SymbologyType defaultSymbologyType() const override;
private:
NGL::INGLLogger &m_logger;
static AdvancedSymbology::Injury stateToInjury(const ProjectDataManagement::VulnerabilityState &state);
std::shared_ptr<ParticipantManagement::Interface::Dtc> m_ppmDtc;
@@ -20,6 +20,8 @@ public:
~SelectTextDialog();
protected:
NGL::INGLLogger &m_logger;
Ui_SelectTextDialog *ui;
private:
@@ -180,6 +180,8 @@ private slots:
private:
NGL::INGLLogger &m_logger;
void resetGUI();
void updateGUI();
void updateSymbolAttributesWidgets();
@@ -105,7 +105,7 @@ FlmSubscriber::FlmSubscriber(const std::shared_ptr<FileManagement::Interface::Dt
: m_logger(NGL::NGLLoggerBootstrap::getNGLRootLogger().getNGLLogger("AdvSymbology.FlmSubscriber"))
, d(new Private())
{
INFO_LOG() << Q_FUNC_INFO << " m_counter =" << ++d->m_counter;
INFO_LOG(m_logger) << Q_FUNC_INFO << " m_counter =" << ++d->m_counter;
d->m_flmDtc = flmDtc;
d->m_flmFtc = flmFtc;
d->m_opmDtc = opmDtc;
@@ -122,7 +122,7 @@ FlmSubscriber::FlmSubscriber(const std::shared_ptr<FileManagement::Interface::Dt
FlmSubscriber::~FlmSubscriber()
{
INFO_LOG() << Q_FUNC_INFO << " m_counter =" << d->m_counter--;
INFO_LOG(m_logger) << Q_FUNC_INFO << " m_counter =" << d->m_counter--;
if (d->m_reFetchTimer)
d->m_reFetchTimer->stop();
@@ -154,9 +154,9 @@ bool FlmSubscriber::createFlmSymbolProxy(int type_placeholder)
updateFileContentMap(data);
};
if (!d->m_flmDtc->fileContents(cb))
ERROR_LOG() << Q_FUNC_INFO << " Error performing fileContents";
ERROR_LOG(m_logger) << Q_FUNC_INFO << " Error performing fileContents";
INFO_LOG() << Q_FUNC_INFO << " m_fileContentMap.size()=" << d->m_fileContentMap.size() ;
INFO_LOG(m_logger) << Q_FUNC_INFO << " m_fileContentMap.size()=" << d->m_fileContentMap.size() ;
@@ -181,7 +181,7 @@ bool FlmSubscriber::createFlmSymbolProxy(int type_placeholder)
fcsRef.monitoring.replyState = FileContentStruct::Requested;
} else {
fcsRef.monitoring.replyState = FileContentStruct::RequestFailure;
ERROR_LOG() << "Error requesting FileContentData, fileContentId=" << fileContentId;
ERROR_LOG(m_logger) << "Error requesting FileContentData, fileContentId=" << fileContentId;
}
}
@@ -192,7 +192,7 @@ bool FlmSubscriber::createFlmSymbolProxy(int type_placeholder)
const int randomOffset = rand() % 10 + 5;
QTimer::singleShot(randomOffset, this , [this]()
{
DEBUG_LOG() << "start ReFetchingTimer";
DEBUG_LOG(m_logger) << "start ReFetchingTimer";
d->m_reFetchTimer->start();
});
@@ -204,11 +204,11 @@ void FlmSubscriber::onGetFileContentDataReply(const FileManagement::GetFileConte
{
const int32_t fileContentId = reply.id();
TRACE_LOG() << Q_FUNC_INFO << " START, " << fileContentId;
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START, " << fileContentId;
if (!d->m_fileContentMap.contains(fileContentId))
{
ERROR_LOG() << Q_FUNC_INFO << " fileContentId unknown, fileContentId=" << fileContentId;
ERROR_LOG(m_logger) << Q_FUNC_INFO << " fileContentId unknown, fileContentId=" << fileContentId;
return;
}
@@ -218,7 +218,7 @@ void FlmSubscriber::onGetFileContentDataReply(const FileManagement::GetFileConte
const QString &operatorName = fcData.operatorName;
const qint64 lastModified = fcData.lastModified;
DEBUG_LOG() << Q_FUNC_INFO
DEBUG_LOG(m_logger) << Q_FUNC_INFO
<< " fileContentId=" << fileContentId
<< " name=" << name
<< " operatorName=" << operatorName
@@ -234,7 +234,7 @@ void FlmSubscriber::onGetFileContentDataReply(const FileManagement::GetFileConte
QImage image;
if (!svgToImage(QByteArray::fromRawData(reinterpret_cast<const char*>(&reply.content().at(0)), reply.content().size()), image))
{
ERROR_LOG() << Q_FUNC_INFO << " svgToImage failed, fileContentId=" << fileContentId;
ERROR_LOG(m_logger) << Q_FUNC_INFO << " svgToImage failed, fileContentId=" << fileContentId;
fcData.monitoring.replyState = FileContentStruct::ReplyFailure;
return;
}
@@ -265,7 +265,7 @@ void FlmSubscriber::onGetFileContentDataReply(const FileManagement::GetFileConte
}
else
{
ERROR_LOG() << Q_FUNC_INFO << " xmlSymbolContent is empty, fileContentId=" << fileContentId;
ERROR_LOG(m_logger) << Q_FUNC_INFO << " xmlSymbolContent is empty, fileContentId=" << fileContentId;
fcData.monitoring.replyState = FileContentStruct::ReplyFailure;
}
break;
@@ -273,24 +273,24 @@ void FlmSubscriber::onGetFileContentDataReply(const FileManagement::GetFileConte
case FileContentStruct::SymbolType::UnsupportedSymbol:
{
ERROR_LOG() << Q_FUNC_INFO << " unsupported symbol found, fileContentId=" << fileContentId;
ERROR_LOG(m_logger) << Q_FUNC_INFO << " unsupported symbol found, fileContentId=" << fileContentId;
fcData.monitoring.replyState = FileContentStruct::ReplyFailure;
break;
}
}
TRACE_LOG() << Q_FUNC_INFO << " END";
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
}
bool FlmSubscriber::svgToImage(const QByteArray &svgByteArray, QImage &imageOut)
{
TRACE_LOG() << Q_FUNC_INFO << " START";
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START";
QSvgRenderer svgRenderer;
if (!svgRenderer.load(svgByteArray))
{
ERROR_LOG() << Q_FUNC_INFO << " svgRenderer.load failed";
ERROR_LOG(m_logger) << Q_FUNC_INFO << " svgRenderer.load failed";
return false;
}
@@ -304,7 +304,7 @@ bool FlmSubscriber::svgToImage(const QByteArray &svgByteArray, QImage &imageOut)
svgRenderer.render(&painter);
painter.end();
TRACE_LOG() << Q_FUNC_INFO << " END";
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END";
return true;
}
@@ -383,7 +383,7 @@ void FlmSubscriber::checkForReFetching()
void FlmSubscriber::onFileContentChanged(const FileManagement::FileContent &data, DataModification modType)
{
TRACE_LOG() << Q_FUNC_INFO
TRACE_LOG(m_logger) << Q_FUNC_INFO
<< " data.id=" << data.id()
<< " data.fileStatus=" << data.fileStatus().underlying()
<< " modType=" << modType
@@ -432,13 +432,13 @@ void FlmSubscriber::onFileContentChanged(const FileManagement::FileContent &data
FileManagement::GetFileContentDataRequest request(fileContentId);
if (!d->m_flmFtc->getFileContentDataRequest(request, this))
ERROR_LOG() << Q_FUNC_INFO << "Error reading FileContentData, fileContentId=" << fileContentId;
ERROR_LOG(m_logger) << Q_FUNC_INFO << "Error reading FileContentData, fileContentId=" << fileContentId;
break;
}
case DataModification::eRemoved:
{
DEBUG_LOG() << Q_FUNC_INFO
DEBUG_LOG(m_logger) << Q_FUNC_INFO
<< " modType=" << modType
<< " fileContentId=" << fileContentId
<< " fileContentName=" << data.name();
@@ -448,7 +448,7 @@ void FlmSubscriber::onFileContentChanged(const FileManagement::FileContent &data
if (!d->m_symbolProxy.removeSymbol(fileContentId))
ERROR_LOG() << Q_FUNC_INFO << " removeSymbol failed"
ERROR_LOG(m_logger) << Q_FUNC_INFO << " removeSymbol failed"
<< " fileContentId=" << fileContentId
<< " fileContentName='" << data.name() << "'"
<< " contains=" << d->m_fileContentMap.contains(fileContentId);
@@ -460,7 +460,7 @@ void FlmSubscriber::onFileContentChanged(const FileManagement::FileContent &data
void FlmSubscriber::updateFileContentMap(const FileManagement::FileContent &data)
{
TRACE_LOG() << Q_FUNC_INFO << " START"
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START"
<< " d->m_fileContentMap.size()=" << d->m_fileContentMap.size()
<< " fileContentId=" << data.id()
<< " data.isDeleted()=" <<data.isDeleted()
@@ -534,7 +534,7 @@ void FlmSubscriber::updateFileContentMap(const FileManagement::FileContent &data
}
} else {
ERROR_LOG() << Q_FUNC_INFO
ERROR_LOG(m_logger) << Q_FUNC_INFO
<< " QJsonParseError->errorString: '" << parseError.errorString() << "'"
<< ", offset: " << parseError.offset;
}
@@ -542,7 +542,7 @@ void FlmSubscriber::updateFileContentMap(const FileManagement::FileContent &data
d->m_fileContentMap[fileContentId] = fcData;
TRACE_LOG() << Q_FUNC_INFO << " END"
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END"
<< " d->m_fileContentMap.size()=" << d->m_fileContentMap.size()
<< " fileContentId=" << data.id()
<< " data.isDeleted()=" <<data.isDeleted()
@@ -573,7 +573,7 @@ void FlmSubscriber::onLocalSymbolProxyEtsSymbolRemoved(qint32 fileContentId, con
{
AdvancedSymbology::SymbolDictionary &dict =
AdvancedSymbology::SymbolDictionary::dictionary(symbologyType);
INFO_LOG() << Q_FUNC_INFO << " dict.removeEtsSymbol:"
INFO_LOG(m_logger) << Q_FUNC_INFO << " dict.removeEtsSymbol:"
<< " symbologyType='" << (int)symbologyType << "'"
<< ", name='" << name << "'"
<< ", fileContentId=" << fileContentId;
@@ -589,7 +589,7 @@ void FlmSubscriber::onLocalSymbolProxyXmlSymbolAdded(qint32 fileContentId,
const QString &xmlContent,
const QStringList &usrTags)
{
TRACE_LOG() << Q_FUNC_INFO << " START"
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START"
<< " fileContentId=" << fileContentId
<< " name='" << name << "'";
@@ -600,25 +600,25 @@ void FlmSubscriber::onLocalSymbolProxyXmlSymbolAdded(qint32 fileContentId,
AdvancedSymbology::SymbolDictionary &dict =
AdvancedSymbology::SymbolDictionary::dictionary(symbologyType);
if (!this->setXmlSymbolToDict(dict, fileContentId, operatorName, lastModified, name, xmlContent, usrTags))
ERROR_LOG() << Q_FUNC_INFO << " dict.setXmlSymbolToDict failed"
ERROR_LOG(m_logger) << Q_FUNC_INFO << " dict.setXmlSymbolToDict failed"
<< ", symbologyType='" << (int)symbologyType << "'"
<< ", name='" << name << "'";
}
}
TRACE_LOG() << Q_FUNC_INFO << " END"
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END"
<< " fileContentId=" << fileContentId
<< " name='" << name << "'";
}
void FlmSubscriber::onLocalSymbolProxyXmlSymbolRemoved(qint32 fileContentId)
{
TRACE_LOG() << Q_FUNC_INFO << " START" << " fileContentId=" << fileContentId;
TRACE_LOG(m_logger) << Q_FUNC_INFO << " START" << " fileContentId=" << fileContentId;
for (const SymbologyType &symbologyType : std::as_const(d->m_symbolDictionaryToUpdate))
{
AdvancedSymbology::SymbolDictionary &dict =
AdvancedSymbology::SymbolDictionary::dictionary(symbologyType);
DEBUG_LOG() << Q_FUNC_INFO << " dict.removeXmlSymbol:"
DEBUG_LOG(m_logger) << Q_FUNC_INFO << " dict.removeXmlSymbol:"
<< " symbologyType='" << symbologyType << "'"
<< ", fileContentId=" << fileContentId;
@@ -627,7 +627,7 @@ void FlmSubscriber::onLocalSymbolProxyXmlSymbolRemoved(qint32 fileContentId)
dict.removeXmlSymbol(sidc);
dict.removeXmlSymbol(fileContentId);
}
TRACE_LOG() << Q_FUNC_INFO << " END" << " fileContentId=" << fileContentId;
TRACE_LOG(m_logger) << Q_FUNC_INFO << " END" << " fileContentId=" << fileContentId;
}
@@ -638,7 +638,7 @@ void FlmSubscriber::onLocalSymbolProxyXmlSymbolRemoved(qint32 fileContentId)
bool FlmSubscriber::connectFlmSymbolProxy(int type_placeholder, SymbologyType symbologyType)
{
Q_UNUSED(type_placeholder);
TRACE_LOG() << Q_FUNC_INFO << " m_fileContentMap.size()=" << d->m_fileContentMap.size() ;
TRACE_LOG(m_logger) << Q_FUNC_INFO << " m_fileContentMap.size()=" << d->m_fileContentMap.size() ;
d->m_symbolDictionaryToUpdate.insert(symbologyType);
@@ -701,12 +701,12 @@ bool FlmSubscriber::setEtsSymbolToDict(SymbolDictionary &dict,
if (!dict.setEtsSymbol(fileContentId, symProps.sidc(), symProps, image))
{
ERROR_LOG() << Q_FUNC_INFO << " dict.insertExtraSymbol failed"
ERROR_LOG(m_logger) << Q_FUNC_INFO << " dict.insertExtraSymbol failed"
<< ", fileContentId=" << fileContentId << ", name='" << name << "'";
return false;
}
else
INFO_LOG() << Q_FUNC_INFO << " dict.insertExtraSymbol done"
INFO_LOG(m_logger) << Q_FUNC_INFO << " dict.insertExtraSymbol done"
<< ", fileContentId=" << fileContentId << ", name='" << name << "'";
return true;
@@ -731,7 +731,7 @@ bool FlmSubscriber::setXmlSymbolToDict(SymbolDictionary &dict,
bool success = dict.setXmlSymbol(fileContentId, name, operatorName, lastModified, xmlContent, symProps);
if (!success)
ERROR_LOG() << Q_FUNC_INFO << " setXmlSymbol failed:"
ERROR_LOG(m_logger) << Q_FUNC_INFO << " setXmlSymbol failed:"
<< ", file-id=" << fileContentId
<< ", filenameid='" << name << "'";
return success;
@@ -40,6 +40,8 @@ public:
bool connectFlmSymbolProxy(int type_placeholder, SymbologyType symbologyType) override;
private:
NGL::INGLLogger &m_logger;
bool setEtsSymbolToDict(SymbolDictionary &dict,
qint32 fileContentId,
const QString &name,