This bug has been migrated to another issue tracking site. It has been closed here and may no longer be being monitored.

If you would like to get updates for this issue, or to participate in it, you may do so at Red Hat Issue Tracker .
Bug 2255002 - Inconsistency in filtering resources by boolean options
Summary: Inconsistency in filtering resources by boolean options
Keywords:
Status: CLOSED MIGRATED
Alias: None
Product: Red Hat OpenStack
Classification: Red Hat
Component: openstack-octavia
Version: 17.1 (Wallaby)
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: zstream
: 17.1
Assignee: Gregory Thiemonge
QA Contact: Bruna Bonguardo
Greg Rakauskas
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-12-18 13:29 UTC by Lukas Piwowarski
Modified: 2024-12-06 15:50 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2024-12-06 15:49:27 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Launchpad.net octavia/+bug/2045803 0 None None None 2023-12-18 13:29:11 UTC
OpenStack gerrit 903081 0 None NEW Fix incorrect filtering when using bool attrs 2023-12-18 15:53:39 UTC
Red Hat Issue Tracker   OSP-30922 0 None None None 2024-12-06 15:49:27 UTC
Red Hat Issue Tracker OSP-33159 0 None None None 2024-12-06 15:50:58 UTC

Description Lukas Piwowarski 2023-12-18 13:29:11 UTC
Description of problem:

There seems to be an inconsistency in filtering resources [1] using boolean options.

For example, when I try to filter out members of a pool using admin_state_up boolean value then values like 'true' and 'false' work as expected.

However, when I want to filter out all members using the backup (or other boolean fields like 'enabled') field then 'true'/'false' values do not work as expected. The user must use the values stored in the database 1/0 instead.

curl -H 'Content-Type: application/json' \
     -H 'Accept: application/json' \
     -H 'X-Auth-Token: XXXXX' \
     http://xxxxx/load-balancer/v2.0/lbaas/pools/XXXX/members?backup=true

I get non-backup members from the pool in the response. See the attached file for more examples. In the file, I work with 1 backup member and 2 default members.

[1] https://docs.openstack.org/api-ref/load-balancer/v2/#filtering-and-column-selection


Note You need to log in before you can comment on or make changes to this bug.