Skip to content

Commit

Permalink
rrd_updates: output JSON in the same structure as XML
Browse files Browse the repository at this point in the history
the data field is not part of meta. see the XML generator at
ocaml/libs/xapi-rrd/lib/rrd_updates.ml line 124

The issue was introduced when serialization was changed to use yojson:
xapi-project/xcp-rrd@048b0e3

Signed-off-by: Pau Ruiz Safont <[email protected]>
  • Loading branch information
psafont committed Feb 14, 2024
1 parent 75c28b3 commit f60c526
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ocaml/libs/xapi-rrd/lib/rrd_updates.ml
Original file line number Diff line number Diff line change
Expand Up @@ -194,9 +194,9 @@ let json_of_t t =
; ("rows", int (Array.length t.data))
; ("columns", int (Array.length t.legend))
; ("legend", array (map_to_list string t.legend))
; ("data", array (map_to_list data_record t.data))
]
)
; ("data", array (map_to_list data_record t.data))
]
in
Yojson.to_string meta
Expand Down

0 comments on commit f60c526

Please sign in to comment.