Docstring fixes for enginefacade
There were some issues with the docstrings, and there are probably still issues that I didn't get around to fixing. Change-Id: I84d60621246776f77f9022f0f1d61792edccbfb0
This commit is contained in:
parent
14c955cf6d
commit
b49e181a86
@ -183,12 +183,12 @@ class _TransactionFactory(object):
|
||||
|
||||
The configurational options given here act as **defaults**
|
||||
when the :class:`._TransactionFactory` is configured using
|
||||
a :class:`.oslo.config.cfg.ConfigOpts` object; the options
|
||||
present within the :class:`.oslo.config.cfg.ConfigOpts` **take
|
||||
a :class:`oslo_config.cfg.ConfigOpts` object; the options
|
||||
present within the :class:`oslo_config.cfg.ConfigOpts` **take
|
||||
precedence** versus the arguments passed here. By default,
|
||||
the :class:`._TransactionFactory` loads in the configuration from
|
||||
:data:`oslo.config.cfg.CONF`, after applying the
|
||||
:data:`oslo.db.options.database_opts` configurational defaults to it.
|
||||
:data:`oslo_config.cfg.CONF`, after applying the
|
||||
:data:`oslo_db.options.database_opts` configurational defaults to it.
|
||||
|
||||
.. seealso::
|
||||
|
||||
@ -206,7 +206,7 @@ class _TransactionFactory(object):
|
||||
Behavior here is the same as that of
|
||||
:meth:`._TransactionFactory.configure_defaults`,
|
||||
with the exception that values specified here will **supersede** those
|
||||
setup in the :class:`.oslo.config.cfg.ConfigOpts` options.
|
||||
setup in the :class:`oslo_config.cfg.ConfigOpts` options.
|
||||
|
||||
.. seealso::
|
||||
|
||||
@ -841,9 +841,8 @@ writer = _context_manager.writer
|
||||
class LegacyEngineFacade(object):
|
||||
"""A helper class for removing of global engine instances from oslo.db.
|
||||
|
||||
.. deprecated::
|
||||
EngineFacade is deprecated. Please use
|
||||
oslo.db.sqlalchemy.enginefacade for new development.
|
||||
.. deprecated:: 1.12.0
|
||||
Please use :mod:`oslo_db.sqlalchemy.enginefacade` for new development.
|
||||
|
||||
As a library, oslo.db can't decide where to store/when to create engine
|
||||
and sessionmaker instances, so this must be left for a target application.
|
||||
@ -866,12 +865,6 @@ class LegacyEngineFacade(object):
|
||||
transactional context (i.e. it's not thread-safe). sessionmaker is
|
||||
a factory of sessions.
|
||||
|
||||
"""
|
||||
def __init__(self, sql_connection, slave_connection=None,
|
||||
sqlite_fk=False, autocommit=True,
|
||||
expire_on_commit=False, _conf=None, _factory=None, **kwargs):
|
||||
"""Initialize engine and sessionmaker instances.
|
||||
|
||||
:param sql_connection: the connection string for the database to use
|
||||
:type sql_connection: string
|
||||
|
||||
@ -920,10 +913,14 @@ class LegacyEngineFacade(object):
|
||||
engine checkin event a sleep(0) will occur to
|
||||
allow other greenthreads to run (defaults to
|
||||
True)
|
||||
|
||||
"""
|
||||
def __init__(self, sql_connection, slave_connection=None,
|
||||
sqlite_fk=False, autocommit=True,
|
||||
expire_on_commit=False, _conf=None, _factory=None, **kwargs):
|
||||
warnings.warn(
|
||||
"EngineFacade is deprecated; please use "
|
||||
"oslo.db.sqlalchemy.enginefacade",
|
||||
"oslo_db.sqlalchemy.enginefacade",
|
||||
exception.OsloDBDeprecationWarning,
|
||||
stacklevel=2)
|
||||
|
||||
@ -997,7 +994,7 @@ class LegacyEngineFacade(object):
|
||||
"""Initialize EngineFacade using oslo.config config instance options.
|
||||
|
||||
:param conf: oslo.config config instance
|
||||
:type conf: oslo.config.cfg.ConfigOpts
|
||||
:type conf: oslo_config.cfg.ConfigOpts
|
||||
|
||||
:param sqlite_fk: enable foreign keys in SQLite
|
||||
:type sqlite_fk: bool
|
||||
|
Loading…
Reference in New Issue
Block a user