LU-4020 hsm: allow copytool event monitoring with JSON
Adds hooks into various llapi_hsm_* functions to emit JSON-formatted
event messages for consumption by a monitoring agent. The copytool
needs to be supplied with an optional --event-fifo argument to
enable this feature.
Incorporates the following work done by Bruno Faccini:
* Put all JSON routines in a separate file/lib to allow for
LGPL licensing.
* Major code cleanup to follow best practices and address review
concerns.
Lustre-commit:
45c9ef1dfff207086665c764c7d500c00aa03c7f
Lustre-change: http://review.whamcloud.com/7790
Signed-off-by: Michael MacDonald <michael.macdonald@intel.com>
Signed-off-by: Bruno Faccini <bruno.faccini@intel.com>
Signed-off-by: Bob Glossman <bob.glossman@intel.com>
Reviewed-by: Andreas Dilger <andreas.dilger@intel.com>
Reviewed-by: Jinshan Xiong <jinshan.xiong@intel.com>
Reviewed-by: Oleg Drokin <oleg.drokin@intel.com>
Change-Id: Icfad0f2093f24fcfec22408d9819d438c6a5e7f1
Reviewed-on: http://review.whamcloud.com/9512
Tested-by: Jenkins
Tested-by: Maloo <hpdd-maloo@intel.com>