Periodically, one of our Gateways will get a “BasicExecutionEngine: Uncaught exception executing self scheduled runnable” error. Sometimes we will get a few in short order, other times they are more spread out. The errors will have one of two different messages, I’ve copied the two different messages below. I made some updates today to the Named Queries to better protect against NULL parameters being passed in. This seems to have reduced the frequency of the errors - and it appears that we now only get the error with the short error message - but they still trigger periodically (sometimes every few minutes, other times, every few seconds).
Lastly, I turned on Trace Logging for the NamedQueries.executor and noticed that the errors seem to only occur during “Next maint interval is X millis. ExpirationMap size is Y, cache size is Y” log messages. Not sure if this points to anything but thought it was interesting. I’ve included a portion of this trace below (last snippit). That is not all of the “maint interval” messages in the log, there were a lot more but didn’t think adding all of them would help anyone. Let me know if there are any other logs that would help.
Ignition 7.9.8 (b2018060714)
Windows 7 PC 64-bit
8 Core 2.4 GHz
32 GB Ram (24 GB allocated to Ignition)
SSD
Error message that appears with a more detailed message:
INFO | jvm 1 | 2018/12/20 10:34:43 | java.lang.NullPointerException: null
INFO | jvm 1 | 2018/12/20 10:34:43 | at com.inductiveautomation.ignition.gateway.project.NamedQueryExecutor.run(NamedQueryExecutor.java:239)
INFO | jvm 1 | 2018/12/20 10:34:43 | at com.inductiveautomation.ignition.common.execution.impl.BasicExecutionEngine$SelfSchedulingRunner.run(BasicExecutionEngine.java:483)
INFO | jvm 1 | 2018/12/20 10:34:43 | at com.inductiveautomation.ignition.common.execution.impl.BasicExecutionEngine$TrackedTask.run(BasicExecutionEngine.java:565)
INFO | jvm 1 | 2018/12/20 10:34:43 | at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
INFO | jvm 1 | 2018/12/20 10:34:43 | at java.util.concurrent.FutureTask.run(Unknown Source)
INFO | jvm 1 | 2018/12/20 10:34:43 | at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(Unknown Source)
INFO | jvm 1 | 2018/12/20 10:34:43 | at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(Unknown Source)
INFO | jvm 1 | 2018/12/20 10:34:43 | at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
INFO | jvm 1 | 2018/12/20 10:34:43 | at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
INFO | jvm 1 | 2018/12/20 10:34:43 | at java.lang.Thread.run(Unknown Source)
Other times this error will appear (since updating the Named Queries this is the only message that has appeared):
INFO | jvm 1 | 2018/12/20 11:09:43 | E [C.BasicExecutionEngine ] [19:09:43]: Uncaught exception executing self scheduled runnable.
INFO | jvm 1 | 2018/12/20 11:09:43 | java.lang.NullPointerException: null
Log with NamedQueries.executor set to Trace:
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553091920 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | E [C.BasicExecutionEngine ] [19:09:43]: Uncaught exception executing self scheduled runnable.
INFO | jvm 1 | 2018/12/20 11:09:43 | java.lang.NullPointerException: null
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553177449 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553180015 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553248439 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553251432 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553274525 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553265117 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553293770 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553301040 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553343805 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553353640 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553363476 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553350219 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553367325 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553384003 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553383148 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553407524 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553417360 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553421637 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553432755 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553456276 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553466967 millis. ExpirationMap size is 2, cache size is 2
INFO | jvm 1 | 2018/12/20 11:09:43 | T [N.executor ] [19:09:43]: Next maint interval is 6890553475520 millis. ExpirationMap size is 2, cache size is 2
... Plus MANY more lines of the same thing