When the RESET event goes through the execute() method, some of the elements in the data array could be null. When this happens, the execute() method should return null; rather than throwing a SiddhiAppRuntimeException. When the execute() method returns null, Siddhi properly handles it. This is the same behaviour that is there in the expression executors in the Siddhi core (For example, refer AddExpressionExecutorInt class in Siddhi core).
Ran FindSecurityBugs plugin and verified report? yes
Confirmed that this PR doesn't commit any keys, passwords, tokens, usernames, or other secrets? yes
Migrations (if applicable)
The functions listed under this extension will now return null, when a null input is given.
Test environment
Mac OS 10.13.1 (17B1003)
java version "1.8.0_171"
Java(TM) SE Runtime Environment (build 1.8.0_171-b11)
Java HotSpot(TM) 64-Bit Server VM (build 25.171-b11, mixed mode)
Purpose
Fix https://github.com/siddhi-io/siddhi-execution-time/issues/58
Goals
Avoid unnecessory error logs in the console.
Approach
When the RESET event goes through the execute() method, some of the elements in the data array could be null. When this happens, the execute() method should return null; rather than throwing a SiddhiAppRuntimeException. When the execute() method returns null, Siddhi properly handles it. This is the same behaviour that is there in the expression executors in the Siddhi core (For example, refer AddExpressionExecutorInt class in Siddhi core).
Documentation
N/A as this is a bug fix.
Certification
N/A as this is a bug fix.
Automation tests
Security checks
Migrations (if applicable)
The functions listed under this extension will now return null, when a null input is given.
Test environment
Mac OS 10.13.1 (17B1003) java version "1.8.0_171" Java(TM) SE Runtime Environment (build 1.8.0_171-b11) Java HotSpot(TM) 64-Bit Server VM (build 25.171-b11, mixed mode)