-
Notifications
You must be signed in to change notification settings - Fork 2
Add indexAllProperties config #272
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
base: master
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -254,6 +254,35 @@ | |
| }</pre> | ||
| </section> | ||
|
|
||
| <section> | ||
| <h3 id="IndexAllProperties">Index All Properties</h3> | ||
|
|
||
| <p> | ||
| By default the extension will index only values for properties for which facets are configured. | ||
| Via this setting, you can make the extension index values for all properties instead. | ||
| </p> | ||
|
|
||
| <p> | ||
| Indexing values for all properties is useful | ||
| when you want to be able to run structured queries for properties not shown in the UI. It is also | ||
| useful to avoid having to rebuild the search index whenever you add a new property to the UI. | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
I think this can be misunderstood. I get this refers to the faceted search UI, but I can see how this might look like it's referring to the general UI (including Wikibase). Adding an existing property (already indexed) in the faceted search config works automatically. But when a new property is added on the wiki and the config, then the index must still be rebuilt. The hook for defining the fields to be indexed is separate from the hook returning the data. |
||
| </p> | ||
|
|
||
| <p> | ||
| Downsides of indexing values for all properties include needing additional storage space for the | ||
| search index and increased time and CPU resources to (re)build said index. | ||
| </p> | ||
|
|
||
| <p> | ||
| Example configuration: | ||
| </p> | ||
|
|
||
| <pre> | ||
| { | ||
| "indexAllProperties": true | ||
| }</pre> | ||
| </section> | ||
|
|
||
| <section> | ||
| <h3 id="FullExample">{{msg-wikibase-faceted-search-config-help-example}}</h3> | ||
|
|
||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As per https://github.com/ProfessionalWiki/WikibaseFacetedSearch/pull/51/files#r1901363923, it seems we should explicitly tell elastic "there is no value" for all properties not present in the statement list, to avoid keeping data for removed statements in the index.
So we need to replace this "IDs of all properties present in the statement list" with "IDs of all properties in the wiki"
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@malberts makes sense to you?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That sounds correct. And also relates to defining all properties in #272 (comment)