glance.db.sqlalchemy.metadef_api package¶
Submodules¶
glance.db.sqlalchemy.metadef_api.namespace module¶
-
glance.db.sqlalchemy.metadef_api.namespace.
create
(context, values, session)[source]¶ Create a namespace, raise if namespace already exists.
-
glance.db.sqlalchemy.metadef_api.namespace.
delete
(context, name, session)[source]¶ Raise if not found, has references or not visible
-
glance.db.sqlalchemy.metadef_api.namespace.
delete_cascade
(context, name, session)[source]¶ Raise if not found, has references or not visible
-
glance.db.sqlalchemy.metadef_api.namespace.
get
(context, name, session)[source]¶ Get a namespace by name, raise if not found
glance.db.sqlalchemy.metadef_api.object module¶
-
glance.db.sqlalchemy.metadef_api.object.
count
(context, namespace_name, session)[source]¶ Get the count of objects for a namespace, raise if ns not found
-
glance.db.sqlalchemy.metadef_api.object.
delete
(context, namespace_name, object_name, session)[source]¶
-
glance.db.sqlalchemy.metadef_api.object.
delete_by_namespace_name
(context, namespace_name, session)[source]¶
glance.db.sqlalchemy.metadef_api.property module¶
-
glance.db.sqlalchemy.metadef_api.property.
count
(context, namespace_name, session)[source]¶ Get the count of properties for a namespace, raise if ns not found
-
glance.db.sqlalchemy.metadef_api.property.
delete
(context, namespace_name, property_name, session)[source]¶
-
glance.db.sqlalchemy.metadef_api.property.
delete_by_namespace_name
(context, namespace_name, session)[source]¶
-
glance.db.sqlalchemy.metadef_api.property.
delete_namespace_content
(context, namespace_id, session)[source]¶ Use this def only if the ns for the id has been verified as visible
glance.db.sqlalchemy.metadef_api.resource_type module¶
-
glance.db.sqlalchemy.metadef_api.resource_type.
create
(context, values, session)[source]¶ Create a resource_type, raise if it already exists.
-
glance.db.sqlalchemy.metadef_api.resource_type.
delete
(context, name, session)[source]¶ Delete a resource type or raise if not found or is protected
-
glance.db.sqlalchemy.metadef_api.resource_type.
get
(context, name, session)[source]¶ Get a resource type, raise if not found
glance.db.sqlalchemy.metadef_api.resource_type_association module¶
-
glance.db.sqlalchemy.metadef_api.resource_type_association.
create
(context, namespace_name, values, session)[source]¶ Create an association, raise if already exists or ns not found.
-
glance.db.sqlalchemy.metadef_api.resource_type_association.
delete
(context, namespace_name, resource_type_name, session)[source]¶ Delete an association or raise if not found
-
glance.db.sqlalchemy.metadef_api.resource_type_association.
delete_namespace_content
(context, namespace_id, session)[source]¶ Use this def only if the ns for the id has been verified as visible
glance.db.sqlalchemy.metadef_api.tag module¶
-
glance.db.sqlalchemy.metadef_api.tag.
count
(context, namespace_name, session)[source]¶ Get the count of objects for a namespace, raise if ns not found
-
glance.db.sqlalchemy.metadef_api.tag.
delete_by_namespace_name
(context, namespace_name, session)[source]¶
-
glance.db.sqlalchemy.metadef_api.tag.
delete_namespace_content
(context, namespace_id, session)[source]¶ Use this def only if the ns for the id has been verified as visible
-
glance.db.sqlalchemy.metadef_api.tag.
get_all
(context, namespace_name, session, filters=None, marker=None, limit=None, sort_key='created_at', sort_dir='desc')[source]¶ Get all tags that match zero or more filters.
Parameters: - filters – dict of filter keys and values.
- marker – tag id after which to start page
- limit – maximum number of namespaces to return
- sort_key – namespace attribute by which results should be sorted
- sort_dir – direction in which results should be sorted (asc, desc)