Fix share/snapshot list API with count param

Bug #2033604 reported by kiran pawar
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Shared File Systems Service (Manila)
Fix Released
Undecided
kiran pawar

Bug Description

Manila share list and share snapshot list APIs, return list of shares and snapshots respectively. In addition these API support param '--count' which return count of shares and snapshots in respective API. However it is observed that these APIs return incorrect count as they return share instances and share snapshot instances count while list returned contains only shares and share snapshots respectively.

Fix this by making sure count return correct value of shares and not share instances. Similar is applicable for share snapshots.

kiran pawar (kpdev)
Changed in manila:
assignee: nobody → kiran pawar (kpdev)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to manila (master)

Fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/manila/+/893345

Changed in manila:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to manila (master)

Reviewed: https://review.opendev.org/c/openstack/manila/+/893345
Committed: https://opendev.org/openstack/manila/commit/9e835496dc2e87d1137749e6420852e41735bf4f
Submitter: "Zuul (22348)"
Branch: master

commit 9e835496dc2e87d1137749e6420852e41735bf4f
Author: Kiran Pawar <email address hidden>
Date: Thu Aug 31 08:33:54 2023 +0000

    Fix count in the response of shares/snapshots list API

    Share/Snapshot list API returns count of shares/snapshotsi along-with
    list of resource objects. The list returned by API contains correct
    entries of shares/snapshots but it returns the wrong count as it
    ShareInstances/SnapshotInstances. So filter queries by unique
    share_id/snapshot_id.

    Closes-bug: #2033604
    Change-Id: I13c415767b0d126563f9553df415de564b3901d6

Changed in manila:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to manila (stable/2023.2)

Fix proposed to branch: stable/2023.2
Review: https://review.opendev.org/c/openstack/manila/+/895919

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to manila (stable/2023.2)

Reviewed: https://review.opendev.org/c/openstack/manila/+/895919
Committed: https://opendev.org/openstack/manila/commit/6b61b065b0ce1620bed228b6e4d34cb8773761b7
Submitter: "Zuul (22348)"
Branch: stable/2023.2

commit 6b61b065b0ce1620bed228b6e4d34cb8773761b7
Author: Kiran Pawar <email address hidden>
Date: Thu Aug 31 08:33:54 2023 +0000

    Fix count in the response of shares/snapshots list API

    Share/Snapshot list API returns count of shares/snapshotsi along-with
    list of resource objects. The list returned by API contains correct
    entries of shares/snapshots but it returns the wrong count as it
    ShareInstances/SnapshotInstances. So filter queries by unique
    share_id/snapshot_id.

    Closes-bug: #2033604
    Change-Id: I13c415767b0d126563f9553df415de564b3901d6
    (cherry picked from commit 9e835496dc2e87d1137749e6420852e41735bf4f)

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/manila 17.1.0

This issue was fixed in the openstack/manila 17.1.0 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/manila 18.0.0.0rc1

This issue was fixed in the openstack/manila 18.0.0.0rc1 release candidate.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.