"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "doc/source/contributor/filtering-responsibilities.rst" between
keystone-17.0.0.tar.gz and keystone-18.0.0.tar.gz

About: OpenStack Keystone (Core Service: Identity) provides an authentication and authorization service for other OpenStack services. Provides a catalog of endpoints for all OpenStack services.
The "Victoria" series (latest release).

filtering-responsibilities.rst  (keystone-17.0.0):filtering-responsibilities.rst  (keystone-18.0.0)
skipping to change at line 17 skipping to change at line 17
a copy of the License at a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0 http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS, WITHOUT distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
License for the specific language governing permissions and limitations License for the specific language governing permissions and limitations
under the License. under the License.
========================================================== ============================================================
Filtering responsibilities between controllers and drivers Filtering responsibilities between API resources and drivers
========================================================== ============================================================
Keystone supports the specification of filtering on list queries as part of the Keystone supports the specification of filtering on list queries as part of the
v3 identity API. By default these queries are satisfied in the controller v3 identity API. By default these queries are satisfied in the API resource when
class when a controller calls the ``wrap_collection`` method at the end of a it calls the ``wrap_collection`` method at the end of a ``get`` method. However
``list_{entity}`` method. However, to enable optimum performance, any driver ,
can implement some or all of the specified filters (for example, by adding to enable optimum performance, any driver can implement some or all of the speci
filtering to the generated SQL statements to generate the list). fied
filters (for example, by adding filtering to the generated SQL statements to gen
The communication of the filter details between the controller level and its erate
drivers is handled by the passing of a reference to a Hints object, the list).
which is a list of dicts describing the filters. A driver that satisfies a
filter must delete the filter from the Hints object so that when it is returned The communication of the filter details between the API resource and its drivers
to the controller level, it knows to only execute any unsatisfied is
filters. handled by the passing of a reference to a Hints object, which is a list of dict
s
describing the filters. A driver that satisfies a filter must delete the filter
from
the Hints object so that when it is returned to the API, it knows to only execut
e any
unsatisfied filters.
The contract for a driver for ``list_{entity}`` methods is therefore: The contract for a driver for ``list_{entity}`` methods is therefore:
* It MUST return a list of entities of the specified type * It MUST return a list of entities of the specified type
* It MAY either just return all such entities, or alternatively reduce the * It MAY either just return all such entities, or alternatively reduce the
list by filtering for one or more of the specified filters in the passed list by filtering for one or more of the specified filters in the passed
Hints reference, and removing any such satisfied filters. An exception to Hints reference, and removing any such satisfied filters. An exception to
this is that for identity drivers that support domains, then they should this is that for identity drivers that support domains, then they should
at least support filtering by domain_id. at least support filtering by domain_id.
 End of changes. 2 change blocks. 
15 lines changed or deleted 21 lines changed or added

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