Handler, DataAssembler receives raw data messages (for now only ev44 and it doesn't matter if it's fake or not) and use NexusContainer to assemble them into the whole nexus structure and send the assembled nexus structure to the message router again.
_nexus_helpers.replace_subdataset create a shallow copy from root, to the point of insertion so that the previously assembled dictionary is not affected by the update.
In order to update the nexus structure (in this case, dictionary) without affecting the previous data, there are helper functions for handling/filtering nested dictionary/list and validating the whole structure.
Following-up Issues
For now, NexusContainer.insert_ev44 method only replaces the data, but since it is now shallow copying the original structure, it is not guaranteed that the DataAssembler is looking at the latest data if they are being appended, not replaced. Related issue: #182.
And I expected DataAssembler will later take care of merging multiple messages by simply concatenating them or using the average. Related issue: #133
Continued from #177 Fixes #134
Main Changes
Handler,
DataAssembler
receives raw data messages (for now onlyev44
and it doesn't matter if it's fake or not) and useNexusContainer
to assemble them into the whole nexus structure and send the assembled nexus structure to the message router again._nexus_helpers.replace_subdataset
create a shallow copy from root, to the point of insertion so that the previously assembled dictionary is not affected by the update.In order to update the nexus structure (in this case, dictionary) without affecting the previous data, there are helper functions for handling/filtering nested dictionary/list and validating the whole structure.
Following-up Issues
For now,
NexusContainer.insert_ev44
method only replaces the data, but since it is now shallow copying the original structure, it is not guaranteed that theDataAssembler
is looking at thelatest
data if they are beingappended
, notreplaced
. Related issue: #182.And I expected
DataAssembler
will later take care of merging multiple messages by simply concatenating them or using the average. Related issue: #133