yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #02333
[Bug 1161195] Re: Non admin user can't search shared networks when db don't support BOOLEAN.
** Changed in: quantum/grizzly
Status: Fix Committed => Fix Released
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to quantum.
https://bugs.launchpad.net/bugs/1161195
Title:
Non admin user can't search shared networks when db don't support
BOOLEAN.
Status in OpenStack Quantum (virtual network service):
Fix Committed
Status in quantum grizzly series:
Fix Released
Bug description:
Below quantum command cannot return shared networks correctly when the backend database doesn't support BOOLEAN type.
quantum --os-username user1 --os-password pass --os-tenant user1-tenant net-list
It will fail with a SQL statement token error at runtime.
Take IBM DB2 for example, SQLAlchemy maps the column 'shared' in quantum.networks as SMALLINT.
Generated SQL error:
[CLI Driver][DB2/LINUXX8664] SQL0104N An unexpected token "END-OF-STATEMENT" was found following "? OR networks.shared". Expected tokens may include: "<interval_qualifier>". SQLSTATE=42601 SQLCODE=-104 'SELECT networks.tenant_id AS networks_tenant_id, networks.id AS networks_id, networks.name AS networks_name, networks.status AS networks_status, networks.admin_state_up AS networks_admin_state_up, networks.shared AS networks_shared \nFROM networks LEFT OUTER JOIN externalnetworks ON networks.id = externalnetworks.network_id \nWHERE externalnetworks.network_id IS NOT NULL OR networks.tenant_id = ? OR networks.shared'
"OR networks.shared" is not supported by databases which don't support BOOLEAN type.
It can be made more compatible by changing to "OR networks.shared = ?" .
To manage notifications about this bug go to:
https://bugs.launchpad.net/quantum/+bug/1161195/+subscriptions