hscan: fix long-standing bug with node memory data
There is a long-standing bug in hscan, due to the serialization workflow. Basically, hscan loads data from the remote cluster(s), processes it via Loader.mergeData and Loader.checkData, then serializes it. The Loader function will update the node memory values as if the down instances were running, and then hscan saves the _modified_ values. When another program (e.g. hbal) loads the text files, it will re-apply the Loader functions, in effect subtracting the instance memory twice, which is course offers a wrong cluster view. To fix this bug, we change a bit the internal workflow in hscan, so that we serialize the unmodified cluster data, and only use the modified one for the display of cluster state (and verification that yes, we can load the data). Signed-off-by:Iustin Pop <iustin@google.com> Reviewed-by:
Balazs Lecz <leczb@google.com>
Please register or sign in to comment