The session write_close was moved to the earliest point in the script
that does not modify the session. This is currently always after
$OUTPUT->header()
To support transitions from one search engine to a different one, or
to a different installation of the same kind, this feature allows for
queries to use a different search engine from indexing. So you can
reindex (and do all other search operation) on one server, while
user queries are unaffected on a different server.
This feature supports changing between search engine types, and also
between two Solr installations.
As of 3.5 a search plugin can define the result orders it supports.
When a search plugin defines multiple sort orders and the search is
conducted without a context (no context query param in the URL),
the code to load the available sort orders from the enabled search
backend is never called.
This patch gets the supported search orders for the enabled search
engine regardless of context being provided or not. As prior, the
search order selection will not display if the only result order
option is relevance.
Implements a mechanism by which search engines can provide different
result orderings, and implements a 'by location' ordering within the
Solr search engine (available whenever the user starts their search
from within a course or activity).
Ensures that Solr will return available results, even if there are many
misses when using check_access(), by asking Solr for more results if the
counter says there should be more.
Improves performance by ending processing as soon as the requested page
of results is processed. Remaining number of pages is an "estimate"
based on the total result count from Solr and how many items we have
rejected up to this point.
Introducing both APIs in moodle along with:
- search_box widget to add a tiny search box
- admin settings with setup steps helper
- cache for search results
- template for a search result
- php unit stuff
Many thanks to Tomasz Muras, Prateek Sachan and Daniel Neis for their contributions, for starting this development
and for pushing for it to be completed. Also thanks to other contributors: Jonathan Harker and eugeneventer.