nova/nova/cmd
Matt Riedemann b501fa7a92 Handle special characters in database connection URL netloc
When calling "nova-manage cell_v2 simple_cell_setup" or
"nova-manage cell_v2 map_cell0" without passing in the
--database_connection option, we read the [database]/connection
URL from nova.conf, try to split the URL and then create a
default connection based on the name of the original connection,
so if you're cell database's name is 'nova' you'd end up with
'nova_cell0' for the cell0 database name in the URL.

The problem is the database connection URL has credentials in the
netloc and if the password has special characters in it, those can
mess up the URL split, like splitting on ? which is normally denoting
the beginning of the path in a URL.

This change handles special characters in the password by using
a nice DB connection URL parsing utility method available in
sqlalchemy to get the database name out of the connection URL string
so we can replace it properly with the _cell0 suffix.

Adds a release note as this bug causes issues when upgrading.

Change-Id: I7a7678e4af8160e6f48b96095154fca6ca48ff09
Closes-Bug: #1673613
(cherry picked from commit 9a9a620ea2)
2017-05-22 11:20:55 -04:00
..
__init__.py move eventlet GREENDNS override to top level 2014-12-08 17:41:03 -05:00
api.py Avoid Forcing the Translation of Translatable Variables 2016-10-04 01:18:59 +00:00
api_metadata.py Remove conductor local api:s and 'use_local' config option 2016-10-18 14:26:06 +02:00
api_os_compute.py Device tagging API support 2016-06-29 20:55:16 -07:00
baseproxy.py baseproxy: stop requiring CONF.verbose 2016-05-16 16:57:21 +02:00
cells.py Remove deprecated manager option in cells.py 2016-08-02 16:54:09 +00:00
cert.py conf: remove deprecated cert_topic option 2016-11-23 10:53:36 -06:00
common.py Trivial: add ability to define action description 2016-12-20 15:19:09 +03:00
compute.py Remove conductor local api:s and 'use_local' config option 2016-10-18 14:26:06 +02:00
conductor.py conf: Remove deprecated service manager opts 2016-12-05 23:28:49 +08:00
console.py Config options: Centralize console options 2016-04-06 15:32:24 +00:00
consoleauth.py Config options: Centralize consoleauth options 2016-03-31 15:13:46 +00:00
dhcpbridge.py Remove conductor local api:s and 'use_local' config option 2016-10-18 14:26:06 +02:00
idmapshift.py Fix invalid import order 2016-07-04 11:23:52 +05:30
manage.py Handle special characters in database connection URL netloc 2017-05-22 11:20:55 -04:00
network.py conf: Remove deprecated service manager opts 2016-12-05 23:28:49 +08:00
novncproxy.py config options: fix the missed cli options of novncproxy 2016-04-04 18:05:32 +08:00
policy_check.py Adds nova-policy-check cmd 2016-08-29 14:59:58 +08:00
scheduler.py Scheduler calling the Placement API 2017-01-27 16:36:34 -08:00
serialproxy.py config options: centralize section "serial_console" 2015-11-19 11:00:20 +01:00
spicehtml5proxy.py config options: centralize 'spice' options 2016-04-11 10:34:05 +00:00
status.py Allow nova-status to work with custom ca for placement 2017-02-23 14:12:30 +00:00
xvpvncproxy.py Revert "Enable options for oslo.reports" 2015-12-05 16:12:52 +00:00