"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "cyborg/db/sqlalchemy/api.py" between
openstack-cyborg-8.0.0.tar.gz and openstack-cyborg-9.0.0.tar.gz

About: OpenStack Cyborg provides a general purpose management framework for acceleration resources.
The "Zed" series (latest release).

api.py  (openstack-cyborg-8.0.0):api.py  (openstack-cyborg-9.0.0)
skipping to change at line 74 skipping to change at line 74
Keyword arguments: Keyword arguments:
:keyword project_only: :keyword project_only:
If set to True, then will do query filter with context's project_id. If set to True, then will do query filter with context's project_id.
if set to False or absent, then will not do query filter with context's if set to False or absent, then will not do query filter with context's
project_id. project_id.
:type project_only: bool :type project_only: bool
""" """
if kwargs.pop("project_only", False): if kwargs.pop("project_only", False):
kwargs["project_id"] = context.tenant kwargs["project_id"] = context.project_id
with _session_for_read() as session: with _session_for_read() as session:
query = sqlalchemyutils.model_query( query = sqlalchemyutils.model_query(
model, session, args, **kwargs) model, session, args, **kwargs)
return query return query
def add_identity_filter(query, value): def add_identity_filter(query, value):
"""Adds an identity filter to a query. """Adds an identity filter to a query.
Filters results by ID, if supplied value is a valid integer. Filters results by ID, if supplied value is a valid integer.
 End of changes. 1 change blocks. 
1 lines changed or deleted 1 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)