Fix extension loading issue in Windows environment #1720
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Purpose
Resolves Intermittent siddhi apps deployment error during server startup as a Windows service #1719. This fix is provided by @dnwick
Resolves NPE observed when 'event.grouping.enabled='false' siddhi-map-json#100
The trpProperties is set in the SourceMapper but it is removed by both SourceMapper and InputEventHandler.
For each event SourceMapper gets, it sets the trpProperties and hands over the event to InputEventHandler. After that removes the trpProperties.
For each event InputEventHandler gets, it removes the trpProperties too (it is unclear why it is doing this duplicate work).
Problem occurs when a batch of events comes to SourceMapper and it invokes the InputEventHandler multiple times (once for each event in the batch). Since InputEventHandler removes the trpProperties each time it gets an event; but the SourceMapper only sets it once for the whole batch, the 2nd event in the batch gets null for the trpProperties. This is the rootcause of this issue.
In this fix, we assume that only the SourceMapper submits events to the InputEventHandler. So setting/removal of trpProperties is handled solely by the SourceMapper.
Release note
Fixes #1719
Fixes siddhi-io/siddhi-map-json#100
Automation tests
Security checks