Revamp search API
Nobody has claimed this yet.
- Dominant language
- No language data
- Stars
- 0
- Forks
- 0
- PR merge metrics
- No merged PRs in 30d
Description
Plan for new search system:
Search driver (eg. Algolia) is called upon to update its index each time a post/discussion is changed
(Each post is a separate object in the index which contains not only post content but also its discussion's title/tags/other metadata)
q = foo "bar baz" (author:toby OR author:franz) is:following
- Parse
qinto an abstracted query object . eg. https://github.com/pimcore/search-query-parser or https://github.com/netgen/query-translator - Loop through each
Termin the query object, allow gambits to match and convert term into aWhereobject to be processed by search driver - Extensions may also populate the query object to enact permissions, eg. add a
Whereto restrict results to only tags that the user can see - Search driver builds its vendor-specific query by inspecting query object's
Terms/Wheres, returns list of discussion IDs
However, this is complex and will take a while to implement, so it would be wise to keep it slated for 0.2 (as per current roadmap). In the meantime, we are doing flarum/framework#1339
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the linked flarum/framework#1339 issue and the current 0.2 roadmap, then compare the proposed parser, Term/Where, extension, and search-driver responsibilities with the existing search implementation. This issue does not identify files, tests, or an agreed implementation boundary, and completion is deferred rather than defined.
Written by the indexing model from the issue text.
Assessment
- Domain
- search
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100