Skip to content

Commit

Permalink
Merge e10f04a into aea5f9b
Browse files Browse the repository at this point in the history
  • Loading branch information
lukasgraf committed Sep 8, 2018
2 parents aea5f9b + e10f04a commit 112eed0
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion docs/source/searching.rst
Expand Up @@ -8,7 +8,7 @@ Content in a Plone site can be searched for by invoking the ``/@search`` endpoin
GET /plone/@search HTTP/1.1
Accept: application/json
A search is **contextual** by default, i.e. it is bound to a specific collection and searches within that collection and any sub-collections.
A search is **contextual** by default, i.e. it is bound to a specific context (a *collection* in HTTP REST terms) and searches within that collection and any sub-collections.

Since a Plone site is also a collection, we therefore have a global search (by invoking the ``/@search`` endpoint on the site root) and contextual searches (by invoking that endpoint on any other context) all using the same pattern.

Expand All @@ -25,6 +25,17 @@ Search results are represented similar to collections:
The default representation for search results is a summary that contains only the most basic information.
In order to return specific metadata columns, see the documentation of the ``metadata_fields`` parameter below.

.. note::
A search invoked on a container will by default **include that container
itself** as part of the search results. This is the same behavior as displayed by
ZCatalog, which is used internally.
If you add the query string
parameter ``depth=1`` to your search, you will only get **immediate**
children of the container, and the container itself also won't be part
of the results. See the Plone docs on
`searching for content within a folder <https://docs.plone.org/develop/plone/searching_and_indexing/query.html#searching-for-content-within-a-folder>`_.
for more details.

.. note::
Search results results will be **batched** if the size of the
resultset exceeds the batch size. See :doc:`/batching` for more
Expand Down

0 comments on commit 112eed0

Please sign in to comment.