Skip to content

Commit d71cef8

Browse files
committed
DPL: check for state transition updates also in input-proxy busy loop
1 parent a52acfc commit d71cef8

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

Framework/Core/src/ExternalFairMQDeviceProxy.cxx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@
3232
#include "Framework/DeviceState.h"
3333
#include "Framework/Monitoring.h"
3434
#include "Framework/SendingPolicy.h"
35+
#include "Framework/DataProcessingHelpers.h"
3536
#include "Headers/DataHeader.h"
3637
#include "Headers/Stack.h"
3738
#include "DecongestionService.h"
@@ -864,6 +865,10 @@ DataProcessorSpec specifyExternalFairMQDeviceProxy(char const* name,
864865

865866
bool didSendParts = false;
866867
for (size_t ci = 0; ci < channels.size(); ++ci) {
868+
// check for state transition request every 10th input channel to avoid large delays of EoS timers
869+
if (ci > 0 && ci % 10 == 0) {
870+
ctx.services().get<DeviceState>().transitionHandling = DataProcessingHelpers::updateStateTransition(ctx.services(), ctx.services().get<DeviceContext>().processingPolicies);
871+
}
867872
std::string const& channel = channels[ci];
868873
int waitTime = channels.size() == 1 ? -1 : 1;
869874
int maxRead = 1000;

0 commit comments

Comments
 (0)