]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
pybind/mgr/pg_autoscaler: fix progress event of the autoscaler
authorKamoltat Sirivadhna <ksirivad@redhat.com>
Tue, 9 Sep 2025 11:28:17 +0000 (11:28 +0000)
committerKamoltat Sirivadhna <ksirivad@redhat.com>
Tue, 9 Sep 2025 18:38:31 +0000 (18:38 +0000)
commite4e784aa32def2b8f3a5fc95fc9168c9aa1d5526
tree3494679adb073096923a21448b2d70f4c614709f
parentfbffe1d6df33909bca51e4c1d1beac480586fa8a
pybind/mgr/pg_autoscaler: fix progress event of the autoscaler

Problem:
We are comparing the wrong value when determining whether the Autoscaler event should be completed or not,
we compared pool_data["pg_num"] == pool_data["pg_num_target"] which will always return true since pool_data["pg_num_target"]
is not actual the target pg we are trying to scale towards, but rather the previous calculated value
that we
are expected to already reached based on previous values.

Solution:
Use the correct value which is comparing pool_data[‘pg_num’] == ev.pg_num_target.

Fixes: https://tracker.ceph.com/issues/72857
Signed-off-by: Kamoltat Sirivadhna <ksirivad@redhat.com>
src/pybind/mgr/pg_autoscaler/module.py