@

Home 

OpenStack Study: glance

OpenStack Index

Previous

Next

def image_member_count(context, image_id):

def _can_show_deleted(context):

def image_tag_set_all(context, image_id, tags):

def image_tag_create(context, image_id, value, session=None):

def image_tag_delete(context, image_id, value, session=None):

def _image_tag_delete_all(context, image_id, delete_time=None, session=None):

def image_tag_get_all(context, image_id, session=None):

def user_get_storage_usage(context, owner_id, image_id=None, session=None):

def _task_info_format(task_info_ref):

def _task_info_create(context, task_id, values, session=None):

def _task_info_update(context, task_id, values, session=None):

def _task_info_get(context, task_id, session=None):

def task_create(context, values, session=None):

def _pop_task_info_values(values):

def task_update(context, task_id, values, session=None):

def task_get(context, task_id, session=None, force_show_deleted=False):

def task_delete(context, task_id, session=None):

def task_get_all(context, filters=None, marker=None, limit=None, sort_key='created_at', sort_dir='desc', admin_as_user=False):

def _is_task_visible(context, task):

def _task_get(context, task_id, session=None, force_show_deleted=False):

def _task_update(context, task_ref, values, session=None):

def _task_format(task_ref, task_info_ref=None):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\manage.py

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\schema.py

def from_migration_import(module_name, fromlist):

def create_tables(tables):

def drop_tables(tables):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\001_add_images_table.py

def define_images_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\002_add_image_properties_table.py

def define_image_properties_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\003_add_disk_format.py

def get_images_table(meta):

def get_image_properties_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\004_add_checksum.py

def get_images_table(meta):

def get_image_properties_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\005_size_big_integer.py

def get_images_table(meta):

def get_image_properties_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\006_key_to_name.py

def get_images_table(meta):

def get_image_properties_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\007_add_owner.py

def get_images_table(meta):

def get_image_properties_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\008_add_image_members_table.py

def get_images_table(meta):

def get_image_properties_table(meta):

def get_image_members_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\009_add_mindisk_and_minram.py

def get_images_table(meta):

def get_image_properties_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\010_default_update_at.py

def get_images_table(meta):

def get_image_properties_table(meta):

def get_image_members_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\011_make_mindisk_and_minram_notnull.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\012_id_to_uuid.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

def _upgrade_sqlite(t_images, t_image_members, t_image_properties):

def _upgrade_db2(t_images, t_image_members, t_image_properties):

def _add_db2_constraints():

def _remove_db2_constraints():

def _downgrade_db2(t_images, t_image_members, t_image_properties):

def _downgrade_sqlite(t_images, t_image_members, t_image_properties):

def _upgrade_other(t_images, t_image_members, t_image_properties, dialect):

def _downgrade_other(t_images, t_image_members, t_image_properties, dialect):

def _sqlite_table_swap(t_image_members, t_image_properties, t_images):

def _get_table(table_name, metadata):

def _get_foreign_keys(t_images, t_image_members, t_image_properties, dialect):

def _update_all_ids_to_uuids(t_images, t_image_members, t_image_properties):

def _update_all_uuids_to_ids(t_images, t_image_members, t_image_properties):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\013_add_protected.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\014_add_image_tags_table.py

def define_image_tags_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\015_quote_swift_credentials.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

def migrate_location_credentials(migrate_engine, to_quoted):

def legacy_parse_uri(uri, to_quote):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\016_add_status_image_member.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\017_quote_encrypted_swift_credentials.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

def migrate_location_credentials(migrate_engine, to_quoted):

def decrypt_location(uri):

def encrypt_location(uri):

def fix_uri_credentials(uri, to_quoted):

def legacy_parse_uri(uri, to_quote):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\018_add_image_locations_table.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\019_migrate_image_locations.py

def get_images_table(meta):

def get_image_locations_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\020_drop_images_table_location.py

def get_images_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\021_set_engine_mysql_innodb.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\022_image_member_index.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

def _get_image_members_table(migrate_engine):

def _get_original_keyname(db):

def _infer_original_keyname(table):

def _sanitize(migrate_engine, table):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\023_placeholder.py

def upgrade(migrate_engine):

def downgrade(migration_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\024_placeholder.py

def upgrade(migrate_engine):

def downgrade(migration_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\025_placeholder.py

def upgrade(migrate_engine):

def downgrade(migration_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\026_add_location_storage_information.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\027_checksum_index.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\028_owner_index.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\029_location_meta_data_pickle_to_string.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\030_add_tasks_table.py

def define_tasks_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\031_remove_duplicated_locations.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\032_add_task_info_table.py

def define_task_info_table(meta):

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\033_add_location_status.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\034_add_virtual_size.py

def upgrade(migrate_engine):

def downgrade(migrate_engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\versions\__init__.py

\OpenStack\glance-2014.1\glance\db\sqlalchemy\migrate_repo\__init__.py

\OpenStack\glance-2014.1\glance\db\sqlalchemy\models.py

def compile_big_int_sqlite(type_, compiler, **kw):

class JSONEncodedDict(TypeDecorator):

    def process_bind_param(self, value, dialect):

    def process_result_value(self, value, dialect):

class GlanceBase(models.ModelBase, models.TimestampMixin):

    def save(self, session=None):

    def delete(self, session=None):

    def keys(self):

    def values(self):

    def items(self):

    def to_dict(self):

class Image(BASE, GlanceBase):

class ImageProperty(BASE, GlanceBase):

class ImageTag(BASE, GlanceBase):

class ImageLocation(BASE, GlanceBase):

class ImageMember(BASE, GlanceBase):

class Task(BASE, GlanceBase):

class TaskInfo(BASE, models.ModelBase):

def register_models(engine):

def unregister_models(engine):

\OpenStack\glance-2014.1\glance\db\sqlalchemy\__init__.py

\OpenStack\glance-2014.1\glance\db\__init__.py

def get_api():

def unwrap(db_api):

class ImageRepo(object):

    def __init__(self, context, db_api):

    def get(self, image_id):

    def list(self, marker=None, limit=None, sort_key='created_at', sort_dir='desc', filters=None, member_status='accepted'):

    def _format_image_from_db(self, db_image, db_tags):

    def _format_image_to_db(self, image):

    def add(self, image):

    def save(self, image):

    def remove(self, image):

class ImageProxy(glance.domain.proxy.Image):

    def __init__(self, image, context, db_api):

    def get_member_repo(self):

class ImageMemberRepo(object):

    def __init__(self, context, db_api, image):

    def _format_image_member_from_db(self, db_image_member):

    def _format_image_member_to_db(self, image_member):

    def list(self):

    def add(self, image_member):

    def remove(self, image_member):

    def save(self, image_member):

    def get(self, member_id):

class TaskRepo(object):

    def _format_task_from_db(self, db_task):

    def _format_task_details_from_db(self, db_task):

    def _format_task_to_db(self, task, task_details=None):

    def __init__(self, context, db_api):

    def get_task_and_details(self, task_id):

    def list_tasks(self, marker=None, limit=None, sort_key='created_at', sort_dir='desc', filters=None):

    def save(self, task, task_details=None):

    def add(self, task, task_details=None):

    def remove(self, task):

\OpenStack\glance-2014.1\glance\domain\proxy.py

def _proxy(target, attr):

 def get_attr(self):

 def set_attr(self, value):

 def del_attr(self):

class Helper(object):

    def __init__(self, proxy_class=None, proxy_kwargs=None):

    def proxy(self, obj):

    def unproxy(self, obj):

class TaskRepo(object):

    def __init__(self, base, task_proxy_class=None, task_proxy_kwargs=None, task_details_proxy_class=None, task_details_proxy_kwargs=None):

    def get_task_and_details(self, task_id):

    def list_tasks(self, *args, **kwargs):

    def add(self, task, task_details=None):

    def save(self, task, task_details=None):

    def remove(self, task):

class Repo(object):

    def __init__(self, base, item_proxy_class=None, item_proxy_kwargs=None):

    def get(self, item_id):

    def list(self, *args, **kwargs):

    def add(self, item):

    def save(self, item):

    def remove(self, item):

class ImageFactory(object):

    def __init__(self, base, proxy_class=None, proxy_kwargs=None):

    def new_image(self, **kwargs):

class ImageMembershipFactory(object):

    def __init__(self, base, image_proxy_class=None, image_proxy_kwargs=None, member_proxy_class=None, member_proxy_kwargs=None):

    def new_image_member(self, image, member_id):

class Image(object):

    def __init__(self, base, member_repo_proxy_class=None, member_repo_proxy_kwargs=None):

    def delete(self):

    def set_data(self, data, size=None):

    def get_data(self):

    def get_member_repo(self):

class Task(object):

    def __init__(self, base):

    def run(self, executor):

    def begin_processing(self):

    def succeed(self, result):

    def fail(self, message):

class TaskDetails(object):

    def __init__(self, base):

class TaskFactory(object):

    def __init__(self, base, task_proxy_class=None, task_proxy_kwargs=None, task_details_proxy_class=None, task_details_proxy_kwargs=None):

    def new_task(self, **kwargs):

    def new_task_details(self, task_id, task_input, message=None, result=None):

\OpenStack\glance-2014.1\glance\domain\__init__.py

def _import_delayed_delete():

class ImageFactory(object):

    def _check_readonly(self, kwargs):

    def _check_unexpected(self, kwargs):

    def _check_reserved(self, properties):

    def new_image(self, image_id=None, name=None, visibility='private', min_disk=0, min_ram=0, protected=False, owner=None, disk_format=None, container_format=None, extra_properties=None, tags=None, **other_args):

class Image(object):

    def __init__(self, image_id, status, created_at, updated_at, **kwargs):

    def status(self):

    def status(self, status):

    def visibility(self):

    def visibility(self, visibility):

    def tags(self):

    def tags(self, value):

    def container_format(self):

    def container_format(self, value):

    def disk_format(self):

    def disk_format(self, value):

    def min_disk(self):

    def min_disk(self, value):

    def min_ram(self):

    def min_ram(self, value):

    def delete(self):

    def get_data(self):

    def set_data(self, data, size=None):

class ExtraProperties(collections.MutableMapping, dict):

    def __getitem__(self, key):

    def __setitem__(self, key, value):

    def __delitem__(self, key):

    def __eq__(self, other):

    def __len__(self):

    def keys(self):

class ImageMembership(object):

    def __init__(self, image_id, member_id, created_at, updated_at, id=None, status=None):

    def status(self):

    def status(self, status):

class ImageMemberFactory(object):

    def new_image_member(self, image, member_id):

class Task(object):

    def __init__(self, task_id, task_type, status, owner, expires_at, created_at, updated_at, task_time_to_live=48):

    def status(self):

    def run(self, executor):

    def _validate_task_status_transition(self, cur_status, new_status):

    def _set_task_status(self, new_status):

    def begin_processing(self):

    def succeed(self, result):

    def fail(self, message):

class TaskDetails(object):

    def __init__(self, task_id, task_input, message, result):

class TaskFactory(object):

    def new_task(self, task_type, owner, task_time_to_live=48):

    def new_task_details(self, task_id, task_input, message=None, result=None):

\OpenStack\glance-2014.1\glance\gateway.py

class Gateway(object):

    def __init__(self, db_api=None, store_api=None, notifier=None, policy_enforcer=None):

    def get_image_factory(self, context):

    def get_image_member_factory(self, context):

    def get_repo(self, context):

    def get_task_factory(self, context):

    def get_task_repo(self, context):

\OpenStack\glance-2014.1\glance\image_cache\base.py

class CacheApp(object):

    def __init__(self):

\OpenStack\glance-2014.1\glance\image_cache\cleaner.py

class Cleaner(base.CacheApp):

    def run(self):

\OpenStack\glance-2014.1\glance\image_cache\client.py

class CacheClient(base_client.BaseClient):

    def delete_cached_image(self, image_id):

    def get_cached_images(self, **kwargs):

    def get_queued_images(self, **kwargs):

    def delete_all_cached_images(self):

    def queue_image_for_caching(self, image_id):

    def delete_queued_image(self, image_id):

    def delete_all_queued_images(self):

def get_client(host, port=None, timeout=None, use_ssl=False, username=None, password=None, tenant=None, auth_url=None, auth_strategy=None, auth_token=None, region=None, is_silent_upload=False, insecure=False):

\OpenStack\glance-2014.1\glance\image_cache\drivers\base.py

class Driver(object):

    def configure(self):

    def set_paths(self):

    def get_cache_size(self):

    def get_cached_images(self):

    def is_cached(self, image_id):

    def is_cacheable(self, image_id):

    def is_queued(self, image_id):

    def delete_all_cached_images(self):

    def delete_cached_image(self, image_id):

    def delete_all_queued_images(self):

    def delete_queued_image(self, image_id):

    def queue_image(self, image_id):

    def clean(self, stall_time=None):

    def get_least_recently_accessed(self):

    def open_for_write(self, image_id):

    def open_for_read(self, image_id):

    def get_image_filepath(self, image_id, cache_status='active'):

    def get_image_size(self, image_id):

    def get_queued_images(self):

\OpenStack\glance-2014.1\glance\image_cache\drivers\sqlite.py

class SqliteConnection(sqlite3.Connection):

    def __init__(self, *args, **kwargs):

    def _timeout(self, call):

    def execute(self, *args, **kwargs):

    def commit(self):

def dict_factory(cur, row):

class Driver(base.Driver):

    def configure(self):

    def initialize_db(self):

    def get_cache_size(self):

    def get_hit_count(self, image_id):

    def get_cached_images(self):

    def is_cached(self, image_id):

    def is_cacheable(self, image_id):

    def is_being_cached(self, image_id):

    def is_queued(self, image_id):

    def delete_all_cached_images(self):

    def delete_cached_image(self, image_id):

    def delete_all_queued_images(self):

    def delete_queued_image(self, image_id):

    def clean(self, stall_time=None):

    def get_least_recently_accessed(self):

    def open_for_write(self, image_id):

        def commit():

        def rollback(e):

    def open_for_read(self, image_id):

    def get_db(self):

    def queue_image(self, image_id):

    def delete_invalid_files(self):

    def delete_stalled_files(self, older_than):

    def get_queued_images(self):

    def get_cache_files(self, basepath):

def delete_cached_file(path):

\OpenStack\glance-2014.1\glance\image_cache\drivers\xattr.py

class Driver(base.Driver):

    def configure(self):

    def get_cache_size(self):

    def get_hit_count(self, image_id):

    def get_cached_images(self):

    def is_cached(self, image_id):

    def is_cacheable(self, image_id):

    def is_being_cached(self, image_id):

    def is_queued(self, image_id):

    def delete_all_cached_images(self):

    def delete_cached_image(self, image_id):

    def delete_all_queued_images(self):

    def delete_queued_image(self, image_id):

    def get_least_recently_accessed(self):

    def open_for_write(self, image_id):

        def set_attr(key, value):

        def commit():

        def rollback(e):

    def open_for_read(self, image_id):

    def queue_image(self, image_id):

    def get_queued_images(self):

    def _reap_old_files(self, dirpath, entry_type, grace=None):

    def reap_invalid(self, grace=None):

    def reap_stalled(self, grace=None):

    def clean(self, stall_time=None):

def get_all_regular_files(basepath):

def delete_cached_file(path):

def _make_namespaced_xattr_key(key, namespace='user'):

def get_xattr(path, key, **kwargs):

def set_xattr(path, key, value):

def inc_xattr(path, key, n=1):

\OpenStack\glance-2014.1\glance\image_cache\drivers\__init__.py

\OpenStack\glance-2014.1\glance\image_cache\prefetcher.py

class Prefetcher(base.CacheApp):

    def __init__(self):

    def fetch_image_into_cache(self, image_id):

    def run(self):

\OpenStack\glance-2014.1\glance\image_cache\pruner.py

class Pruner(base.CacheApp):

    def run(self):

\OpenStack\glance-2014.1\glance\image_cache\__init__.py

class ImageCache(object):

    def __init__(self):

    def init_driver(self):

    def configure_driver(self):

    def is_cached(self, image_id):

    def is_queued(self, image_id):

    def get_cache_size(self):

    def get_hit_count(self, image_id):

    def get_cached_images(self):

    def delete_all_cached_images(self):

    def delete_cached_image(self, image_id):

    def delete_all_queued_images(self):

    def delete_queued_image(self, image_id):

    def prune(self):

    def clean(self, stall_time=None):

    def queue_image(self, image_id):

    def get_caching_iter(self, image_id, image_checksum, image_iter):

    def cache_tee_iter(self, image_id, image_iter, image_checksum):

    def cache_image_iter(self, image_id, image_iter, image_checksum=None):

    def cache_image_file(self, image_id, image_file):

    def open_for_read(self, image_id):

    def get_image_size(self, image_id):

    def get_queued_images(self):

\OpenStack\glance-2014.1\glance\notifier.py

class Notifier(object):

    def __init__(self, strategy=None):

    def warn(self, event_type, payload):

    def info(self, event_type, payload):

    def error(self, event_type, payload):

def format_image_notification(image):

def format_task_notification(task):

class ImageRepoProxy(glance.domain.proxy.Repo):

    def __init__(self, image_repo, context, notifier):

    def save(self, image):

    def add(self, image):

    def remove(self, image):

class ImageFactoryProxy(glance.domain.proxy.ImageFactory):

    def __init__(self, factory, context, notifier):

class ImageProxy(glance.domain.proxy.Image):

    def __init__(self, image, context, notifier):

    def _format_image_send(self, bytes_sent):

    def get_data(self):

    def set_data(self, data, size=None):

class TaskRepoProxy(glance.domain.proxy.TaskRepo):

    def __init__(self, task_repo, context, notifier):

    def add(self, task, task_details=None):

    def remove(self, task):

class TaskFactoryProxy(glance.domain.proxy.TaskFactory):

    def __init__(self, task_factory, context, notifier):

class TaskProxy(glance.domain.proxy.Task):

    def __init__(self, task, context, notifier):

    def run(self, executor):

    def begin_processing(self):

    def succeed(self, result):

    def fail(self, message):

class TaskDetailsProxy(glance.domain.proxy.TaskDetails):

    def __init__(self, task_details, context, notifier):

\OpenStack\glance-2014.1\glance\openstack\common\db\api.py

def safe_for_db_retry(f):

class wrap_db_retry(object):

    def __init__(self, retry_interval, max_retries, inc_retry_interval, max_retry_interval):

    def __call__(self, f):

        def wrapper(*args, **kwargs):

class DBAPI(object):

    def __init__(self, backend_name, backend_mapping=None, lazy=False, **kwargs):

    def _load_backend(self):

    def __getattr__(self, key):

\OpenStack\glance-2014.1\glance\openstack\common\db\exception.py

class DBError(Exception):

    def __init__(self, inner_exception=None):

class DBDuplicateEntry(DBError):

    def __init__(self, columns=[], inner_exception=None):

class DBDeadlock(DBError):

    def __init__(self, inner_exception=None):

class DBInvalidUnicodeParameter(Exception):

class DbMigrationError(DBError):

    def __init__(self, message=None):

class DBConnectionError(DBError):

\OpenStack\glance-2014.1\glance\openstack\common\db\options.py

def set_defaults(sql_connection, sqlite_db, max_pool_size=None, max_overflow=None, pool_timeout=None):

def list_opts():

\OpenStack\glance-2014.1\glance\openstack\common\db\sqlalchemy\migration.py

def _get_unique_constraints(self, table):

def _recreate_table(self, table, column=None, delta=None, omit_uniques=None):

def _visit_migrate_unique_constraint(self, *p, **k):

def patch_migrate():

def db_sync(engine, abs_path, version=None, init_version=0, sanity_check=True):

def _db_schema_sanity_check(engine):

def db_version(engine, abs_path, init_version):

def db_version_control(engine, abs_path, version=None):

def _find_migrate_repo(abs_path):

\OpenStack\glance-2014.1\glance\openstack\common\db\sqlalchemy\models.py

class ModelBase(six.Iterator):

    def save(self, session):

    def __setitem__(self, key, value):

    def __getitem__(self, key):

    def get(self, key, default=None):

    def _extra_keys(self):

    def __iter__(self):

    def __next__(self):

    def next(self):

    def update(self, values):

    def iteritems(self):

class TimestampMixin(object):

class SoftDeleteMixin(object):

    def soft_delete(self, session):

\OpenStack\glance-2014.1\glance\openstack\common\db\sqlalchemy\provision.py

def get_engine(uri):

def _execute_sql(engine, sql, driver):

def create_database(engine):

def drop_database(admin_engine, current_uri):

def main():

\OpenStack\glance-2014.1\glance\openstack\common\db\sqlalchemy\session.py

class SqliteForeignKeysListener(PoolListener):

    def connect(self, dbapi_con, con_record):

def _raise_if_duplicate_entry_error(integrity_error, engine_name):

    def get_columns_from_uniq_cons_or_name(columns):

def _raise_if_deadlock_error(operational_error, engine_name):

def _wrap_db_error(f):

    def _wrap(self, *args, **kwargs):

def _synchronous_switch_listener(dbapi_conn, connection_rec):

def _add_regexp_listener(dbapi_con, con_record):

    def regexp(expr, item):

def _thread_yield(dbapi_con, con_record):

def _ping_listener(engine, dbapi_conn, connection_rec, connection_proxy):

def _set_session_sql_mode(dbapi_con, connection_rec, sql_mode=None):

def _mysql_get_effective_sql_mode(engine):

def _mysql_check_effective_sql_mode(engine):

def _mysql_set_mode_callback(engine, sql_mode):

def _is_db_connection_error(args):

def _raise_if_db_connection_lost(error, engine):

def create_engine(sql_connection, sqlite_fk=False, mysql_sql_mode=None, idle_timeout=3600, connection_debug=0, max_pool_size=None, max_overflow=None, pool_timeout=None, sqlite_synchronous=True, connection_trace=False, max_retries=10, retry_interval=10):

class Query(sqlalchemy.orm.query.Query):

    def soft_delete(self, synchronize_session='evaluate'):

class Session(sqlalchemy.orm.session.Session):

    def query(self, *args, **kwargs):

    def flush(self, *args, **kwargs):

    def execute(self, *args, **kwargs):

def get_maker(engine, autocommit=True, expire_on_commit=False):

def _patch_mysqldb_with_stacktrace_comments():

    def _do_query(self, q):

class EngineFacade(object):

    def __init__(self, sql_connection, sqlite_fk=False, autocommit=True, expire_on_commit=False, **kwargs):

    def get_engine(self):

    def get_session(self, **kwargs):

    def from_config(cls, connection_string, conf, sqlite_fk=False, autocommit=True, expire_on_commit=False):

\OpenStack\glance-2014.1\glance\openstack\common\db\sqlalchemy\test_base.py

class DbFixture(fixtures.Fixture):

    def _get_uri(self):

    def __init__(self, test):

    def setUp(self):

class DbTestCase(test.BaseTestCase):

    def setUp(self):

def backend_specific(*dialects):

    def wrap(f):

        def ins_wrap(self):

class OpportunisticFixture(DbFixture):

    def _get_uri(self):

class OpportunisticTestCase(DbTestCase):

    def setUp(self):

class MySQLOpportunisticFixture(OpportunisticFixture):

class PostgreSQLOpportunisticFixture(OpportunisticFixture):

class MySQLOpportunisticTestCase(OpportunisticTestCase):

class PostgreSQLOpportunisticTestCase(OpportunisticTestCase):

\OpenStack\glance-2014.1\glance\openstack\common\db\sqlalchemy\test_migrations.py

def _have_mysql(user, passwd, database):

def _have_postgresql(user, passwd, database):

def _set_db_lock(lock_path=None, lock_prefix=None):

 def decorator(f):

class BaseMigrationTestCase(test.BaseTestCase):

    def __init__(self, *args, **kwargs):

    def setUp(self):

    def tearDown(self):

    def execute_cmd(self, cmd=None):

    def _reset_pg(self, conn_pieces):

    def _reset_databases(self):

class WalkVersionsMixin(object):

    def _walk_versions(self, engine=None, snake_walk=False, downgrade=True):

    def _migrate_down(self, engine, version, with_data=False):

    def _migrate_up(self, engine, version, with_data=False):

\OpenStack\glance-2014.1\glance\openstack\common\db\sqlalchemy\utils.py

def sanitize_db_url(url):

class InvalidSortKey(Exception):

def paginate_query(query, model, limit, sort_keys, marker=None, sort_dir=None, sort_dirs=None):

def _read_deleted_filter(query, db_model, read_deleted):

def _project_filter(query, db_model, context, project_only):

def model_query(context, model, session, args=None, project_only=False, read_deleted=None):

def get_table(engine, name):

class InsertFromSelect(UpdateBase):

    def __init__(self, table, select):

def visit_insert_from_select(element, compiler, **kw):

class ColumnError(Exception):

    def is_deleted_column_constraint(constraint):

def get_connect_string(backend, database, user=None, passwd=None):

def is_backend_avail(backend, database, user=None, passwd=None):

def get_db_connection_info(conn_pieces):

\OpenStack\glance-2014.1\glance\openstack\common\db\sqlalchemy\__init__.py

\OpenStack\glance-2014.1\glance\openstack\common\db\__init__.py

\OpenStack\glance-2014.1\glance\openstack\common\eventlet_backdoor.py

def _dont_use_this():

def _find_objects(t):

def _print_greenthreads():

def _print_nativethreads():

def initialize_if_enabled():

\OpenStack\glance-2014.1\glance\openstack\common\excutils.py

class save_and_reraise_exception(object):

    def __init__(self):

    def __enter__(self):

    def __exit__(self, exc_type, exc_val, exc_tb):

def forever_retry_uncaught_exceptions(infunc):

    def inner_func(*args, **kwargs):

\OpenStack\glance-2014.1\glance\openstack\common\fileutils.py

def ensure_tree(path):

def read_cached_file(filename, force_reload=False):

def delete_if_exists(path, remove=os.unlink):

def remove_path_on_error(path, remove=delete_if_exists):

def file_open(*args, **kwargs):

def write_to_tempfile(content, path=None, suffix='', prefix='tmp'):

\OpenStack\glance-2014.1\glance\openstack\common\gettextutils.py

def enable_lazy():

def _(msg):

def _log_translation(msg, level):

def install(domain, lazy=False):

class Message(six.text_type):

    def __new__(cls, msgid, msgtext=None, params=None, domain='glance', *args):

    def translate(self, desired_locale=None):

    def _translate_msgid(msgid, domain, desired_locale=None):

    def __mod__(self, other):

    def _sanitize_mod_params(self, other):

    def _trim_dictionary_parameters(self, dict_param):

    def _copy_param(self, param):

    def __add__(self, other):

    def __radd__(self, other):

    def __str__(self):

def get_available_languages(domain):

def translate(obj, desired_locale=None):

def _translate_args(args, desired_locale=None):

class TranslationHandler(handlers.MemoryHandler):

    def __init__(self, locale=None, target=None):

    def setFormatter(self, fmt):

    def emit(self, record):

    def _translate_and_log_record(self, record):

\OpenStack\glance-2014.1\glance\openstack\common\importutils.py

def import_class(import_str):

def import_object(import_str, *args, **kwargs):

def import_object_ns(name_space, import_str, *args, **kwargs):

def import_module(import_str):

def try_import(import_str, default=None):

\OpenStack\glance-2014.1\glance\openstack\common\jsonutils.py

def to_primitive(value, convert_instances=False, convert_datetime=True, level=0, max_depth=3):

def dumps(value, default=to_primitive, **kwargs):

def loads(s):

def load(s):

\OpenStack\glance-2014.1\glance\openstack\common\local.py

class WeakLocal(threading.local):

    def __getattribute__(self, attr):

    def __setattr__(self, attr, value):

\OpenStack\glance-2014.1\glance\openstack\common\lockutils.py

def set_defaults(lock_path):

class _InterProcessLock(object):

    def __init__(self, name):

    def __enter__(self):

    def __exit__(self, exc_type, exc_val, exc_tb):

    def trylock(self):

    def unlock(self):

class _WindowsLock(_InterProcessLock):

    def trylock(self):

    def unlock(self):

class _PosixLock(_InterProcessLock):

    def trylock(self):

    def unlock(self):

        def foo(self, *args):

        def foo(self, *args):

        def bar(self, *args):

    def wrap(f):

        def inner(*args, **kwargs):

        def bar(self, *args):

\OpenStack\glance-2014.1\glance\openstack\common\log.py

def _dictify_context(context):

def _get_binary_name():

def _get_log_file_path(binary=None):

def mask_password(message, secret="***"):

class BaseLoggerAdapter(logging.LoggerAdapter):

    def audit(self, msg, *args, **kwargs):

class LazyAdapter(BaseLoggerAdapter):

    def __init__(self, name='unknown', version='unknown'):

    def logger(self):

class ContextAdapter(BaseLoggerAdapter):

    def __init__(self, logger, project_name, version_string):

    def handlers(self):

    def deprecated(self, msg, *args, **kwargs):

    def process(self, msg, kwargs):

class JSONFormatter(logging.Formatter):

    def __init__(self, fmt=None, datefmt=None):

    def formatException(self, ei, strip_newlines=True):

    def format(self, record):

def _create_logging_excepthook(product_name):

    def logging_excepthook(exc_type, value, tb):

class LogConfigError(Exception):

    def __init__(self, log_config, err_msg):

    def __str__(self):

def _load_log_config(log_config_append):

def setup(product_name, version='unknown'):

def set_defaults(logging_context_format_string):

def _find_facility_from_conf():

class RFCSysLogHandler(logging.handlers.SysLogHandler):

    def __init__(self, *args, **kwargs):

    def format(self, record):

def _setup_logging_from_conf(project, version):

def getLogger(name='unknown', version='unknown'):

def getLazyLogger(name='unknown', version='unknown'):

class WritableLogger(object):

    def __init__(self, logger, level=logging.INFO):

    def write(self, msg):

class ContextFormatter(logging.Formatter):

    def __init__(self, *args, **kwargs):

    def format(self, record):

    def formatException(self, exc_info, record=None):

class ColorHandler(logging.StreamHandler):

    def format(self, record):

class DeprecatedConfig(Exception):

    def __init__(self, msg):

\OpenStack\glance-2014.1\glance\openstack\common\loopingcall.py

class LoopingCallDone(Exception):

    def __init__(self, retvalue=True):

class LoopingCallBase(object):

    def __init__(self, f=None, *args, **kw):

    def stop(self):

    def wait(self):

class FixedIntervalLoopingCall(LoopingCallBase):

    def start(self, interval, initial_delay=None):

        def _inner():

class DynamicLoopingCall(LoopingCallBase):

    def start(self, initial_delay=None, periodic_interval_max=None):

        def _inner():

\OpenStack\glance-2014.1\glance\openstack\common\network_utils.py

def parse_host_port(address, default_port=None):

\OpenStack\glance-2014.1\glance\openstack\common\policy.py

class Rules(dict):

    def load_json(cls, data, default_rule=None):

    def __init__(self, rules=None, default_rule=None):

    def __missing__(self, key):

    def __str__(self):

def set_rules(rules):

def reset():

def check(rule, target, creds, exc=None, *args, **kwargs):

class BaseCheck(object):

    def __str__(self):

    def __call__(self, target, cred):

class FalseCheck(BaseCheck):

    def __str__(self):

    def __call__(self, target, cred):

class TrueCheck(BaseCheck):

    def __str__(self):

    def __call__(self, target, cred):

class Check(BaseCheck):

    def __init__(self, kind, match):

    def __str__(self):

class NotCheck(BaseCheck):

    def __init__(self, rule):

    def __str__(self):

    def __call__(self, target, cred):

class AndCheck(BaseCheck):

    def __init__(self, rules):

    def __str__(self):

    def __call__(self, target, cred):

    def add_check(self, rule):

class OrCheck(BaseCheck):

    def __init__(self, rules):

    def __str__(self):

    def __call__(self, target, cred):

    def add_check(self, rule):

def _parse_check(rule):

def _parse_list_rule(rule):

def _parse_tokenize(rule):

class ParseStateMeta(type):

    def __new__(mcs, name, bases, cls_dict):

def reducer(*tokens):

    def decorator(func):

class ParseState(object):

    def __init__(self):

    def reduce(self):

    def shift(self, tok, value):

    def result(self):

    def _wrap_check(self, _p1, check, _p2):

    def _make_and_expr(self, check1, _and, check2):

    def _extend_and_expr(self, and_expr, _and, check):

    def _make_or_expr(self, check1, _or, check2):

    def _extend_or_expr(self, or_expr, _or, check):

    def _make_not_expr(self, _not, check):

def _parse_text_rule(rule):

def parse_rule(rule):

def register(name, func=None):

    def decorator(func):

class RuleCheck(Check):

    def __call__(self, target, creds):

class RoleCheck(Check):

    def __call__(self, target, creds):

class HttpCheck(Check):

    def __call__(self, target, creds):

class GenericCheck(Check):

    def __call__(self, target, creds):

\OpenStack\glance-2014.1\glance\openstack\common\processutils.py

class InvalidArgumentError(Exception):

    def __init__(self, message=None):

class UnknownArgumentError(Exception):

    def __init__(self, message=None):

class ProcessExecutionError(Exception):

    def __init__(self, stdout=None, stderr=None, exit_code=None, cmd=None, description=None):

class NoRootWrapSpecified(Exception):

    def __init__(self, message=None):

def _subprocess_setup():

def execute(*cmd, **kwargs):

def trycmd(*args, **kwargs):

def ssh_execute(ssh, cmd, process_input=None, addl_env=None, check_exit_code=True):

\OpenStack\glance-2014.1\glance\openstack\common\service.py

class Launcher(object):

    def __init__(self):

    def run_service(service):

    def launch_service(self, service):

    def stop(self):

    def wait(self):

class SignalExit(SystemExit):

    def __init__(self, signo, exccode=1):

class ServiceLauncher(Launcher):

    def _handle_signal(self, signo, frame):

    def wait(self):

class ServiceWrapper(object):

    def __init__(self, service, workers):

class ProcessLauncher(object):

OpenStack Index

Previous

Next