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

@@ -53,7 +53,7 @@ bool CesTestsSmart::init(int domainId, int exerciseId, int testId)
bool bRet = true;
int equipmentTypeIdVehicle = 35;
int equipmentTypeIdSoldier = 30; // dds-Topic Participant-Management::Type
INFO_LOG() << "init begin";
INFO_LOG(m_logger) << "init begin";
m_testId = testId;
m_buildingId = 0; // ism_main_structure_element:id
@@ -141,7 +141,7 @@ bool CesTestsSmart::init(int domainId, int exerciseId, int testId)
void CesTestsSmart::startTest()
{
INFO_LOG() << "startTest m_testId=" << m_testId;
INFO_LOG(m_logger) << "startTest m_testId=" << m_testId;
if (m_testId <= 1) // 1 SMART
{
m_explosionSingle = m_housePos.geographic(5, 5);
@@ -163,7 +163,7 @@ void CesTestsSmart::startTest()
}
else
{
ERROR_LOG() << "Unknown test id = " << m_testId;
ERROR_LOG(m_logger) << "Unknown test id = " << m_testId;
failExit();
}
QTimer::singleShot(8000, this, &CesTestsSmart::failExit);
@@ -185,10 +185,10 @@ void CesTestsSmart::tryCreateDynamicParticipantData()
dp.sampleTime(esTime);
m_DynamicParticipantIndex++;
DEBUG_LOG() << "Publishing DynamicParticipantData";
DEBUG_LOG(m_logger) << "Publishing DynamicParticipantData";
if (!m_ppmDts->publish(dp))
{
ERROR_LOG() << "Error requesting create ParticipantPosition";
ERROR_LOG(m_logger) << "Error requesting create ParticipantPosition";
failExit();
}
}
@@ -212,10 +212,10 @@ void CesTestsSmart::tryCreateParticipantPosition()
pp.sampleTime(posTime);
pp.pos(pos);
DEBUG_LOG() << "Publishing ParticipantPosition";
DEBUG_LOG(m_logger) << "Publishing ParticipantPosition";
if (!m_ppmDts->publish(pp))
{
ERROR_LOG() << "Error requesting create ParticipantPosition";
ERROR_LOG(m_logger) << "Error requesting create ParticipantPosition";
failExit();
}
}
@@ -229,17 +229,17 @@ void CesTestsSmart::tryCreateParticipant()
pt.id(21);
pt.equipmentNumber(61);
DEBUG_LOG() << "Publishing Participant";
DEBUG_LOG(m_logger) << "Publishing Participant";
if (!m_ppmDts->publish(pt))
{
ERROR_LOG() << "Error requesting create Participant";
ERROR_LOG(m_logger) << "Error requesting create Participant";
failExit();
}
}
void CesTestsSmart::checkParticipantEvent()
{
INFO_LOG() << "checkParicipantEvent m_cesDtc->participantEvents().size() =" << m_cesDtc->participantEvents().size();
INFO_LOG(m_logger) << "checkParicipantEvent m_cesDtc->participantEvents().size() =" << m_cesDtc->participantEvents().size();
m_cesDtc->waitForHistoricalDataParticipantEvent();
CentralEffectSimulation::ParticipantEvent participantEvent0 = m_cesDtc->participantEvent(0);
CentralEffectSimulation::ParticipantEvent participantEvent1 = m_cesDtc->participantEvent(1);
@@ -247,7 +247,7 @@ void CesTestsSmart::checkParticipantEvent()
for ( int i = 0; i < m_cesDtc->participantEvents().size(); i++)
{
CentralEffectSimulation::ParticipantEvent participantEvent = m_cesDtc->participantEvent(i);
INFO_LOG() << "Recived ParicipantEvent equipmentNumber:"<<participantEvent.equipmentNumber()
INFO_LOG(m_logger) << "Recived ParicipantEvent equipmentNumber:"<<participantEvent.equipmentNumber()
<< " eventType="<<participantEvent.eventTypeId();
}
@@ -262,7 +262,7 @@ void CesTestsSmart::checkParticipantEvent()
break;
default:
// nothing
ERROR_LOG() << "Error checkParticipantEvent";
ERROR_LOG(m_logger) << "Error checkParticipantEvent";
failExit();
break;
}
@@ -283,10 +283,10 @@ void CesTestsSmart::tryCreateTypeVehicle()
ty.name("HMMWV Utility");
DEBUG_LOG() << "Publishing Type";
DEBUG_LOG(m_logger) << "Publishing Type";
if (!m_ppmDts->publish(ty))
{
ERROR_LOG() << "Error requesting create Type";
ERROR_LOG(m_logger) << "Error requesting create Type";
failExit();
}
}
@@ -304,10 +304,10 @@ void CesTestsSmart::tryCreateTypeSoldier()
ty.name("Soldier");
DEBUG_LOG() << "Publishing Type";
DEBUG_LOG(m_logger) << "Publishing Type";
if (!m_ppmDts->publish(ty))
{
ERROR_LOG() << "Error requesting create Type";
ERROR_LOG(m_logger) << "Error requesting create Type";
failExit();
}
}
@@ -318,7 +318,7 @@ static void setPos(std::vector<Core::GeoPosition> &cont, const QPointF &pos)
void CesTestsSmart::tryCreateAesItemViewSingleExplosion()
{
INFO_LOG() << "trying to send AesItemView AtExplosionAreaSingleExplosions";
INFO_LOG(m_logger) << "trying to send AesItemView AtExplosionAreaSingleExplosions";
AreaEffectSimulation::AesItemView iv;
iv.effectStateId(AreaEffectSimulation::AesEffectState_def::EsActivated);
@@ -343,30 +343,30 @@ void CesTestsSmart::tryCreateAesItemViewSingleExplosion()
setPos(iv.form(), m_housePos.geographic(-10, 20));
setPos(iv.form(), m_housePos.geographic(-10, 30));
DEBUG_LOG() << "Publishing AesItemView";
DEBUG_LOG(m_logger) << "Publishing AesItemView";
if (!m_aesDts->publish(iv))
{
ERROR_LOG() << "Error requesting create AesItemViewSingleExplosions";
ERROR_LOG(m_logger) << "Error requesting create AesItemViewSingleExplosions";
failExit();
}
}
void CesTestsSmart::tryCreateChargeType()
{
DEBUG_LOG() << "Publishing ChargeType";
DEBUG_LOG(m_logger) << "Publishing ChargeType";
ProjectDataManagement::ChargeType ct;
ct.id(m_chargeTypeId);
ct.properties("{\"impactRadius\":25,\"impactEdgeLength\":50,\"isSmart\":true,\"searchRadius\":150}");
if (!m_pdmDts->publish(ct))
{
ERROR_LOG() << "Error publish ChargeType";
ERROR_LOG(m_logger) << "Error publish ChargeType";
failExit();
}
}
void CesTestsSmart::tryCreatePrepareExplosionSingle()
{
INFO_LOG() << "trying to send ExplosionSingle";
INFO_LOG(m_logger) << "trying to send ExplosionSingle";
AreaEffectSimulation::ExplosionSingle es;
const qint64 time = QDateTime::currentMSecsSinceEpoch();
const rti::core::int64 esTime = static_cast<rti::core::int64>(time);
@@ -382,17 +382,17 @@ void CesTestsSmart::tryCreatePrepareExplosionSingle()
es.isCentral(true);
es.effectStart ( QDateTime::currentMSecsSinceEpoch() + 2000);
DEBUG_LOG() << "Publishing ExplosionSingle";
DEBUG_LOG(m_logger) << "Publishing ExplosionSingle";
if (!m_aesDts->publish(es))
{
ERROR_LOG() << "Error publish ExplosionArea";
ERROR_LOG(m_logger) << "Error publish ExplosionArea";
failExit();
}
}
void CesTestsSmart::tryCreateExplosionSingle()
{
INFO_LOG() << "trying to send ExplosionSingle";
INFO_LOG(m_logger) << "trying to send ExplosionSingle";
AreaEffectSimulation::ExplosionSingle es;
const qint64 time = QDateTime::currentMSecsSinceEpoch();
const rti::core::int64 esTime = static_cast<rti::core::int64>(time);
@@ -410,10 +410,10 @@ void CesTestsSmart::tryCreateExplosionSingle()
es.sampleTime(esTime);
es.chargeStruct().chargeTypeId(m_chargeTypeId);
DEBUG_LOG() << "Publishing ExplosionSingle";
DEBUG_LOG(m_logger) << "Publishing ExplosionSingle";
if (!m_aesDts->publish(es))
{
ERROR_LOG() << "Error publish ExplosionArea";
ERROR_LOG(m_logger) << "Error publish ExplosionArea";
failExit();
}
}
@@ -433,7 +433,7 @@ void CesTestsSmart::onSendCesHitRequest(const rti::core::SampleIdentity &cookie,
QDateTime dateTime;
dateTime.setMSecsSinceEpoch(msecs);
DEBUG_LOG() << "onSendCesHitRequest" << "\n"
DEBUG_LOG(m_logger) << "onSendCesHitRequest" << "\n"
<< " request.aesId() = " << request.aesId() << "\n"
<< " request.chargeTypeId() = " << request.chargeTypeId() << "\n"
<< " request.equipmentNumber() = " << request.equipmentNumber() << "\n"
@@ -448,14 +448,14 @@ void CesTestsSmart::onSendCesHitRequest(const rti::core::SampleIdentity &cookie,
void CesTestsSmart::failExit()
{
DEBUG_LOG() << "FailExit";
DEBUG_LOG(m_logger) << "FailExit";
m_bTestsSuccessful = false;
QTimer::singleShot(50, qApp, QCoreApplication::quit);
}
void CesTestsSmart::ExitSuccess()
{
DEBUG_LOG() << "ExitSuccess";
DEBUG_LOG(m_logger) << "ExitSuccess";
m_bTestsSuccessful = true;
QTimer::singleShot(200, qApp, &QCoreApplication::quit);
}