nifi/nifi-commons
Koji Kawamura 4e7a856f77
NIFI-5885 ArrayOutOfBoundsException at EL 'or' and 'and' functions
EL 'or' and 'and' functions can be called multiple times within the same context using the same evaluator instance.
That happens if their subject is derived from an IteratingEvaluator such as 'anyDelineatedValues'.

And if the right hand side expression for such 'or' and 'and' contains another IteratingEvaluator,
then it can be evaluated more than the number of its candidates, ultimately an ArrayOutOfBoundsException is thrown.

This commit makes Or/AndEvaluator caching its right hand side result to prevent that happens.
For 'or' and 'and' functions, the right hand side expression is independant from their subject boolean value.
It's enough evaluating right hand side once, because it returns the same result even with different subjects.

Signed-off-by: Pierre Villard <pierre.villard.fr@gmail.com>

This closes #3212.
2018-12-10 11:47:58 +01:00
..
nifi-data-provenance-utils NIFI-5720-RC3 prepare for next development iteration 2018-10-22 22:16:43 -04:00
nifi-expression-language NIFI-5885 ArrayOutOfBoundsException at EL 'or' and 'and' functions 2018-12-10 11:47:58 +01:00
nifi-flowfile-packager NIFI-5720-RC3 prepare for next development iteration 2018-10-22 22:16:43 -04:00
nifi-hl7-query-language NIFI-5720-RC3 prepare for next development iteration 2018-10-22 22:16:43 -04:00
nifi-json-utils NIFI-5720-RC3 prepare for next development iteration 2018-10-22 22:16:43 -04:00
nifi-logging-utils NIFI-5720-RC3 prepare for next development iteration 2018-10-22 22:16:43 -04:00
nifi-properties NIFI-5673 Set up property/assembly for new auto-load directory 2018-11-01 14:41:10 -04:00
nifi-record NIFI-5333 Added GetMongoRecord. 2018-11-23 15:01:45 +05:30
nifi-record-path NIFI-5757 Using Caffeine instead of slow synchronization on LinkedHashMap for caches - mainly avro schema caches 2018-11-09 14:50:24 -05:00
nifi-schema-utils NIFI-5720-RC3 prepare for next development iteration 2018-10-22 22:16:43 -04:00
nifi-security-utils NIFI-5720-RC3 prepare for next development iteration 2018-10-22 22:16:43 -04:00
nifi-site-to-site-client NIFI-5720-RC3 prepare for next development iteration 2018-10-22 22:16:43 -04:00
nifi-socket-utils NIFI-5720-RC3 prepare for next development iteration 2018-10-22 22:16:43 -04:00
nifi-utils NIFI-5718: Added performance-based unit test (Ignored) for LineDemarcator 2018-11-09 14:27:32 -07:00
nifi-web-utils NIFI-5720-RC3 prepare for next development iteration 2018-10-22 22:16:43 -04:00
nifi-write-ahead-log NIFI-5720-RC3 prepare for next development iteration 2018-10-22 22:16:43 -04:00
pom.xml NIFI-5720-RC3 prepare for next development iteration 2018-10-22 22:16:43 -04:00