Add support for boolean configuration parameters

Bug #1288507 reported by Khyati Sheth
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack DBaaS (Trove)
Fix Released
Low
Auston McReynolds

Bug Description

Currently if configuration parameter is specified as a boolean, it is converted to an int and we need to specify min, max constraints for integer. i.e. for boolean we need to specify min:0, max:1

This behavior is due to a bug in the code, where the int type is checked as isinstance(v, int). Since boolean is a subclass of int in Python, bool types are converted to int.

Fix :
Have isinstance(v, bool) check.

Khyati Sheth (khysheth)
Changed in trove:
assignee: nobody → Khyati Sheth (khysheth)
Khyati Sheth (khysheth)
description: updated
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to trove (master)

Fix proposed to branch: master
Review: https://review.openstack.org/78499

Changed in trove:
status: New → In Progress
Changed in trove:
assignee: Khyati Sheth (khysheth) → Auston McReynolds (amcrn)
description: updated
Changed in trove:
milestone: none → icehouse-rc1
importance: Undecided → Low
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to trove (master)

Reviewed: https://review.openstack.org/78499
Committed: https://git.openstack.org/cgit/openstack/trove/commit/?id=481018d35410feccb1a219d2028870595dd34656
Submitter: Jenkins
Branch: master

commit 481018d35410feccb1a219d2028870595dd34656
Author: Khyati Sheth <email address hidden>
Date: Wed Mar 5 18:29:20 2014 -0800

    Remove Min/Max for Configuration Group Booleans

    boolean configuration-group parameters at the moment require a
    min/max value of 0/1 to work around some faulty logic that is
    meant to validate integer values, but instead validates integer
    and boolean values.

    Closes-Bug: #1288507
    Change-Id: I2d7556621e891b22291c7ef9e9c523e1ce98a047

Changed in trove:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in trove:
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in trove:
milestone: icehouse-rc1 → 2014.1
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.