An enhancement to the SQLAlchemy package that provides persistent item-value stores, arrays, and dictionaries, and an access broker for conveniently managing database access, table setup, and transactions. Everything can be run in an asynchronous fashion using the Twisted framework and its deferred processing capabilities.

Start with database.AccessBroker.

Module database Asynchronous database transactions via SQLAlchemy and Twisted. You will surely have a subclass of AccessBroker.
Module errors Errors relating to database access
Module items Dictionary-like objects with behind-the-scenes database persistence.
Module parray Persistent Three-dimensional array objects.
Module queue Queuing for asynchronous database transactions via SQLAlchemy.
Module selex Convenient select-object usage for asynchronous database transactions via SQLAlchemy.
Package test Unit tests for sasync

From the __init__.py module:

Function engine Specifies the parameters for creating an SQLAlchemy database engine that will be used as a default for all instances of AccessBroker and all persistent objects based thereon.
def engine(url, **kw):

Specifies the parameters for creating an SQLAlchemy database engine that will be used as a default for all instances of AccessBroker and all persistent objects based thereon.

ParametersurlAn RFC-1738 url to a database connection.
strategyThe Strategy describes the general configuration used to create this Engine. The two available values are plain, which is the default, and threadlocal, which applies a 'thread-local context' to implicit executions performed by the Engine. This context is further described in Implicit Connection Contexts. (type: 'plain'.)
poolAn instance of sqlalchemy.pool.Pool to be used as the underlying source for connections, overriding the engine's connect arguments (pooling is described in Connection Pooling). If None, a default Pool (usually QueuePool, or SingletonThreadPool in the case of SQLite) will be created using the engine's connect arguments. (type: None)
pool_sizeThe number of connections to keep open inside the connection pool. This is only used with QueuePool. (type: 5)
max_overflowThe number of connections to allow in 'overflow,' that is connections that can be opened above and beyond the initial five. This is only used with QueuePool. (type: 10)
pool_timeoutnumber of seconds to wait before giving up on getting a connection from the pool. This is only used with QueuePool. (type: 30)
echoif True, the Engine will log all statements as well as a repr() of their parameter lists to the engines logger, which defaults to sys.stdout. The echo attribute of ComposedSQLEngine can be modified at any time to turn logging on and off. If set to the string 'debug', result rows will be printed to the standard output as well. (type: False)
moduleused by database implementations which support multiple DBAPI modules, this is a reference to a DBAPI2 module to be used instead of the engine's default module. For Postgres, the default is psycopg2, or psycopg1 if 2 cannot be found. For Oracle, its cx_Oracle. (type: None)
use_ansiused only by Oracle; when False, the Oracle driver attempts to support a particular 'quirk' of Oracle versions 8 and previous, that the LEFT OUTER JOIN SQL syntax is not supported, and the 'Oracle join' syntax of using <column1>(+)=<column2> must be used in order to achieve a LEFT OUTER JOIN. (type: True)
threadedused by cx_Oracle; sets the threaded parameter of the connection indicating thread-safe usage. cx_Oracle docs indicate setting this flag to False will speed performance by 10-15%. While this defaults to False in cx_Oracle, SQLAlchemy defaults it to True, preferring stability over early optimization. (type: True)
use_oidsused only by Postgres, will enable the column name 'oid' as the object ID column, which is also used for the default sort order of tables. Postgres as of 8.1 has object IDs disabled by default. (type: False)
convert_unicodeif set to True, all String/character based types will convert Unicode values to raw byte values going into the database, and all raw byte values to Python Unicode coming out in result sets. This is an engine-wide method to provide unicode across the board. For unicode conversion on a column-by-column level, use the Unicode column type instead. (type: False)
encodingthe encoding to use for all Unicode translations, both by engine-wide unicode conversion as well as the Unicode type object. (type: 'utf-8')
See Alsohttp://docs.sqlalchemy.org/en/rel_1_0/core/engines.html.
API Documentation for sAsync, generated by pydoctor at 2021-09-18 08:41:22.