]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
src/mon/ConnectionTracker.cc: fix dump
authorKamoltat <ksirivad@redhat.com>
Tue, 30 Apr 2024 02:18:58 +0000 (02:18 +0000)
committerroot <root@vossi06.front.sepia.ceph.com>
Thu, 26 Sep 2024 16:17:35 +0000 (16:17 +0000)
commit4f563f9ea7048ae06f2b40eed96580fdbae1a62f
tree4aae61062bd106f973b65ee1318d8cdf1cadc000
parent6c1daf4534a8346dd586b1f2060f6b58211b7b71
src/mon/ConnectionTracker.cc: fix dump

Problem:

Currently, the ConnectionTracker::dump()
will dump a duplicate key which is not
ideal when you want to write a test that
converts the dump into a JSON since
JSON objects are key-value pairs where
each key must be unique.

Solution:
Use open_array_section and convert
`peer_scores` and `reports` into an
array instead.

Fixes: https://tracker.ceph.com/issues/65695
Signed-off-by: Kamoltat <ksirivad@redhat.com>
(cherry picked from commit c05d4e27160652541870e06ab9001f63040d3cc1)
src/mon/ConnectionTracker.cc