What are the possible causes of a Timer Thread RTE when all of the timers content are poll-groups?
In this case serial polling is done and a condition is defined on the timer.
Normally the timer will move the poll-groups on the execution queue that is running in the protocol thread. In case executing the group would take too long I would expect a Protocol Thread RTE, not a Timer Thread RTE. So when can this occur?
@João, Indeed the TimerThread waits to redo the entire time cycle until the last group in executed by the ProtocolThread. If the execution of that last group is delayed, then the TimerThread will every minute update the watchdog, so no RTE should be created for the TimerThread.
Unless the thread effectively dropped out, I think we'll need a dump of the process to be able to explain this.
As Jan states, a number of issues can cause this problem. It's very difficult to say in general what's causing this and is to be evaluated case by case. A number of issues that can occur:
- thread crashed
- triggers before are stuck (triggering QAction which never finishes)
- timer execution is stuck (add polling groups on the stack)
Stuck in this case can mean e.g. waiting on locks required for safe memory operations. These locks can be triggered by e.g. a user action which temporarily blocks the scheduling of the polling in some cases.
If I look at a protocol pending call, the timer thread remains in there until the last group it set to execute is finished.
If I recall correctly this is used as a flag so that the timer knows it can start another iteration of adding groups to execute.