
The use of plain SQLAlchemy create_engine in Zaqar bypasses lots of oslo_db features that are associated with its version of create_engine, some useful and some critical. Among favorable behaviors that are added: * The SQLite PRAGMA FOREIGN KEYS call is abstracted into the sqlite_fk flag * The engine is given a pessimistic "ping" event, which emits a "SELECT 1" upon connection checkout which will then recycle the connection if the backing database is no longer connected. As we are using a connection pool, if the database has been restarted, or in the case of MySQL a default timeout of eight hours idle has passed, existing pooled connections will be stale. Upcoming SQLAlchemy 1.2 includes this feature as a simple flag but for now, oslo_db implements the event listener as directed by SQLA docs * The errors raised by the DBAPI, and then wrapped by SQLAlchemy, are further sub-classified. In particular, Zaqar seems to use a lot of IntegrityError catches to detect duplicate entry and foreign key constraint conditions. oslo_db parses these out on a per-database-basis into individual DBDuplicateEntry, DBReferenceError, and other error classes, allowing Zaqar to respond specifically to the sub-class of IntegrityError or allow it to propagate if the condition is unhandled. * checks for MySQL SQL_MODE and best practice driver (pymysql) will emit warnings if these conditions are not met. * Gets Zaqar ready for further oslo.db integration and guides new features into oslo_db, including a potential "mysql timezone" setting Change-Id: I16c3ed89e006e132bbd0295be1dfd0b561b2037c Resolves-bug: https://bugs.launchpad.net/tripleo/+bug/1691951
35 lines
1.2 KiB
Plaintext
35 lines
1.2 KiB
Plaintext
# The order of packages is significant, because pip processes them in the order
|
|
# of appearance. Changing the order has an impact on the overall integration
|
|
# process, which may cause wedges in the gate later.
|
|
pbr!=2.1.0,>=2.0.0 # Apache-2.0
|
|
|
|
alembic>=0.8.10 # MIT
|
|
Babel!=2.4.0,>=2.3.4 # BSD
|
|
falcon>=1.0.0 # Apache-2.0
|
|
jsonschema!=2.5.0,<3.0.0,>=2.0.0 # MIT
|
|
iso8601>=0.1.11 # MIT
|
|
keystonemiddleware>=4.12.0 # Apache-2.0
|
|
msgpack-python>=0.4.0 # Apache-2.0
|
|
python-memcached>=1.56 # PSF
|
|
WebOb>=1.7.1 # MIT
|
|
stevedore>=1.20.0 # Apache-2.0
|
|
six>=1.9.0 # MIT
|
|
oslo.cache>=1.5.0 # Apache-2.0
|
|
oslo.config>=4.0.0 # Apache-2.0
|
|
oslo.context>=2.14.0 # Apache-2.0
|
|
oslo.db>=4.21.1 # Apache-2.0
|
|
oslo.i18n!=3.15.2,>=2.1.0 # Apache-2.0
|
|
oslo.log>=3.22.0 # Apache-2.0
|
|
oslo.messaging>=5.19.0 # Apache-2.0
|
|
oslo.reports>=0.6.0 # Apache-2.0
|
|
oslo.serialization>=1.10.0 # Apache-2.0
|
|
oslo.utils>=3.20.0 # Apache-2.0
|
|
oslo.policy>=1.17.0 # Apache-2.0
|
|
osprofiler>=1.4.0 # Apache-2.0
|
|
SQLAlchemy!=1.1.5,!=1.1.6,!=1.1.7,!=1.1.8,>=1.0.10 # MIT
|
|
enum34;python_version=='2.7' or python_version=='2.6' or python_version=='3.3' # BSD
|
|
trollius>=1.0 # Apache-2.0
|
|
autobahn>=0.10.1 # MIT License
|
|
requests!=2.12.2,!=2.13.0,>=2.10.0 # Apache-2.0
|
|
futurist!=0.15.0,>=0.11.0 # Apache-2.0
|