# glance.image_cache.drivers.common module

Common code which will be used in SQLite and centralzed_db driver until SQLite driver is removed from glance.

class glance.image_cache.drivers.common.SqliteConnection(*args, **kwargs)

  Bases: `Connection`

  SQLite connection that retries on database-is-locked errors with a bounded total wait, similar to Swift’s SQLite helper.

  commit()

    Commit any pending transaction to the database.

    If there is no open transaction, this method is a no-op.

  execute(*args, **kwargs)

    Executes an SQL statement.

glance.image_cache.drivers.common.dict_factory(cur, row)

glance.image_cache.drivers.common.get_db(db_path)

  Returns a context manager that produces a database connection that self-closes and calls rollback if an error occurs while using the database connection

this page last updated: 2026-08-19 03:42:39

Except where otherwise noted, this document is licensed under Creative Commons Attribution 3.0 License. See all OpenStack Legal Documents.

found an error? report a bug