Page MenuHomePhabricator

Introduce SearchQuery
Closed, ResolvedPublic

Description

SearchQuery is a immutable class holding all the information known after parsing the query.
This object can be built from a convenient builder class.
It'll be the data that the upcoming query routing mechanism will be based on.
It'll also be the source data for all the query building component.

Details

Related Gerrit Patches:
mediawiki/extensions/CirrusSearch : masterAdd ContextualFilter
mediawiki/extensions/CirrusSearch : masterAdd tilde header support to the new parser
mediawiki/extensions/CirrusSearch : masterAdd support for namespace header in the new parser

Event Timeline

dcausse triaged this task as Medium priority.Mar 16 2018, 3:21 PM
dcausse created this task.
Restricted Application edited projects, added Discovery-Search; removed Discovery-Search (Current work). · View Herald TranscriptMar 16 2018, 3:21 PM
dcausse removed a project: Epic.Mar 16 2018, 3:33 PM
dcausse updated the task description. (Show Details)Mar 21 2018, 9:21 AM
dcausse updated the task description. (Show Details)

What about config and interwiki stuff? I.e., right now interwiki searches also use query builder but with different config. To take decision about how to treat search, this information needs to be available - i.e. Wikibase wants to override local searches in Main space, but not interwiki searches in the same space.

Most of the time the list of requested namespaces will be the criteria used but what happens if 2 extensions request to override for the same set of ns?

Ideally we don't want two extensions messing with search in the same NS. However, it is completely possible that, for example, somebody searches both Main and User space on Wikidata, and those require different searches. Right now the engine just chooses one, but we could possibly - at least in theory - run several searches. That wouldn't be easy since searches can have different results formats, etc. - so I am not sure whether we should support it at all.

Change 460008 had a related patch set uploaded (by DCausse; owner: DCausse):
[mediawiki/extensions/CirrusSearch@master] Add support for prefixed namespace in the new parser

https://gerrit.wikimedia.org/r/460008

Change 460299 had a related patch set uploaded (by DCausse; owner: DCausse):
[mediawiki/extensions/CirrusSearch@master] Add tilde prefix support to the new parser

https://gerrit.wikimedia.org/r/460299

Change 460008 merged by jenkins-bot:
[mediawiki/extensions/CirrusSearch@master] Add support for namespace header in the new parser

https://gerrit.wikimedia.org/r/460008

Change 460299 merged by jenkins-bot:
[mediawiki/extensions/CirrusSearch@master] Add tilde header support to the new parser

https://gerrit.wikimedia.org/r/460299

Change 463432 had a related patch set uploaded (by DCausse; owner: DCausse):
[mediawiki/extensions/CirrusSearch@master] Add ContextualFilter

https://gerrit.wikimedia.org/r/463432

Change 463432 merged by jenkins-bot:
[mediawiki/extensions/CirrusSearch@master] Add ContextualFilter

https://gerrit.wikimedia.org/r/463432

dcausse renamed this task from Introduce InitialSearchContext to Introduce SearchQuery.Oct 4 2018, 2:40 PM
dcausse updated the task description. (Show Details)
debt closed this task as Resolved.Nov 9 2018, 4:42 PM