Database connection pooling improvements
- Implemented new variable ``connection_recycle_time`` responsible for SQLAlchemy's connection recycling - Set new default values for db pooling variables which are inherited from the global ones. Depends-On: https://review.opendev.org/c/openstack/openstack-ansible/+/819424 Change-Id: I28c64b44eadfd726e07cb7159e5d3d94fde106ed
This commit is contained in:
parent
4d4366ed16
commit
4667c80b90
@ -68,6 +68,10 @@ designate_galera_database: designate
|
||||
designate_galera_use_ssl: "{{ galera_use_ssl | default(False) }}"
|
||||
designate_galera_ssl_ca_cert: "{{ galera_ssl_ca_cert | default('') }}"
|
||||
designate_galera_port: "{{ galera_port | default('3306') }}"
|
||||
designate_db_max_overflow: "{{ openstack_db_max_overflow | default('50') }}"
|
||||
designate_db_max_pool_size: "{{ openstack_db_max_pool_size | default('5') }}"
|
||||
designate_db_pool_timeout: "{{ openstack_db_pool_timeout | default('30') }}"
|
||||
designate_db_connection_recycle_time: "{{ openstack_db_connection_recycle_time | default('600') }}"
|
||||
|
||||
## Oslo Messaging
|
||||
# RPC
|
||||
|
@ -373,7 +373,11 @@ endpoint_type = internalURL
|
||||
# SQLAlchemy Storage
|
||||
#-----------------------
|
||||
[storage:sqlalchemy]
|
||||
connection = mysql+pymysql://{{ designate_galera_user }}:{{ designate_galera_password }}@{{ designate_galera_address }}/{{ designate_galera_database }}?charset=utf8{% if designate_galera_use_ssl | bool %}&ssl_verify_cert=true{% if designate_galera_ssl_ca_cert | length > 0 %}&ssl_ca={{ designate_galera_ssl_ca_cert }}{% endif %}{% endif %}
|
||||
connection = mysql+pymysql://{{ designate_galera_user }}:{{ designate_galera_password }}@{{ designate_galera_address }}/{{ designate_galera_database }}?charset=utf8{% if designate_galera_use_ssl | bool %}&ssl_verify_cert=true{% if designate_galera_ssl_ca_cert | length > 0 %}&ssl_ca={{ designate_galera_ssl_ca_cert }}{% endif %}{% endif +%}
|
||||
max_overflow = {{ designate_db_max_overflow }}
|
||||
max_pool_size = {{ designate_db_max_pool_size }}
|
||||
pool_timeout = {{ designate_db_pool_timeout }}
|
||||
connection_recycle_time = {{ designate_db_connection_recycle_time }}
|
||||
|
||||
#connection_debug = 0
|
||||
#connection_trace = False
|
||||
|
Loading…
Reference in New Issue
Block a user