Allow configuration of Nova SQLAlchemy options

Add variables for the following 3 nova.conf vars:
max_overflow (default 10)
max_pool_size (default 5)
pool_timeout (default 30)

This allows for sql tuning to better support bulk operations
(boot/delete) with the ability to define custom values in nova.conf
based on business needs.

Change-Id: Ic427e6822f636a304cbbfaab5ac74a13e912da0f
Closes-Bug: #1447389
This commit is contained in:
Satheesh Ulaganathan 2015-04-29 16:07:29 -07:00
parent 338bd80774
commit 58212d9b8a
2 changed files with 6 additions and 0 deletions

View File

@ -31,6 +31,9 @@ nova_system_home_folder: "/var/lib/{{ nova_system_user_name }}"
## DB ## DB
nova_galera_user: nova nova_galera_user: nova
nova_galera_database: nova nova_galera_database: nova
nova_db_max_overflow: 10
nova_db_max_pool_size: 5
nova_db_pool_timeout: 30
## RPC ## RPC
nova_rpc_backend: nova.openstack.common.rpc.impl_kombu nova_rpc_backend: nova.openstack.common.rpc.impl_kombu

View File

@ -177,6 +177,9 @@ check_revocations_for_cached = False
{% if inventory_hostname not in groups['nova_compute'] %} {% if inventory_hostname not in groups['nova_compute'] %}
[database] [database]
connection = mysql://{{ nova_galera_user }}:{{ nova_container_mysql_password }}@{{ galera_address }}/{{ nova_galera_database }}?charset=utf8 connection = mysql://{{ nova_galera_user }}:{{ nova_container_mysql_password }}@{{ galera_address }}/{{ nova_galera_database }}?charset=utf8
max_overflow = {{ nova_db_max_overflow }}
max_pool_size = {{ nova_db_max_pool_size }}
pool_timeout = {{ nova_db_pool_timeout }}
{% endif %} {% endif %}