Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

8927 plugin search #10489

Merged
merged 24 commits into from
Oct 10, 2022
Merged

8927 plugin search #10489

merged 24 commits into from
Oct 10, 2022

Conversation

arthanson
Copy link
Collaborator

@arthanson arthanson commented Sep 27, 2022

Fixes: #8927

Refactors and adds to the search code to allow two things:

  1. Allow plugins to have search capabilities
  2. Make the search system 'pluggable' so a new Postgres search can be added.

The major changes are moving the search definitions to be class based (from the current dictionary), adding in a pluggable search backend system and making the search registration auto-scan the apps (which requires the class based definitions) to dynamically pick up new apps and plugins.

@arthanson arthanson changed the base branch from develop to feature September 27, 2022 21:38
@arthanson arthanson changed the title DRAFT: 8927 plugin search 8927 plugin search Sep 28, 2022
@arthanson arthanson marked this pull request as ready for review September 28, 2022 15:16
@jeremystretch jeremystretch added the beta Concerns a bug/feature in a beta release label Sep 29, 2022
@jeremystretch
Copy link
Member

This has gone through a few iterations, building on @arthanson's initial work, but ultimately I ended up settling on the following for this FR (with additional work remaining to be done under #10560):

  • The SearchIndex class enables global search for each relevant model
  • Indexes are registered to the application registry using the new register_search() decorator
  • FilterSetSearchBackend retains the existing legacy global search functionality
  • Add the search_indexes config parameter to PluginConfig

We'll undoubtedly need to keep adjusting the search backends implementation under #10560, but this feels like a solid start, and meets the primary objective of enabling global search for plugin models.

@jeremystretch jeremystretch merged commit ffce5d9 into feature Oct 10, 2022
@jeremystretch jeremystretch deleted the 8927-plugin-search branch October 10, 2022 18:01
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 10, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
beta Concerns a bug/feature in a beta release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Search integration in plugins
2 participants