diff options
author | Mike Bayer <mike_mp@zzzcomputing.com> | 2014-12-05 15:52:45 -0500 |
---|---|---|
committer | Roman Podoliaka <rpodolyaka@mirantis.com> | 2014-12-12 12:22:37 +0200 |
commit | 0265aa4e01270b8fc7cab1266b8602e1921c9ddb (patch) | |
tree | c87b21368c80d28c307aa28118ff501fb1d2023b /README.rst | |
parent | 32e5c6096a9523a0d22bbef2569181c281800313 (diff) | |
download | oslo-db-0265aa4e01270b8fc7cab1266b8602e1921c9ddb.tar.gz |
Repair string-based disconnect filters for MySQL, DB2
The two regexp-based filters in exc_filters.py->_is_db_connection_error()
were both incorrectly formed. The tests for these filters would pass
because the fixture also set the is_disconnect flag to True, which
normally would be set by SQLAlchemy, and therefore the
_raise_operational_errors_directly_filter() or possibly
the _raise_for_remaining_DBAPIError() filters would catch this,
view the is_disconnect flag as True, and promote to a DBConnectionError.
However, the _is_db_connection_error() filters are intended to
work independently of whether this flag is set; so two new tests
are added which unset the flag, and ensure that the exception messages
as given are caught here.
Change-Id: I37ddd669b89669730ae1ff07c7bc7a6ba5705f67
Diffstat (limited to 'README.rst')
0 files changed, 0 insertions, 0 deletions