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

XWIKI-22820: Solr field cache uses a lot of RAM #3845

Merged
merged 1 commit into from
Feb 3, 2025

Conversation

michitux
Copy link
Contributor

Jira URL

https://jira.xwiki.org/browse/XWIKI-22820

Changes

Description

  • Configure the "string" field type with docValues="true" as in the default configuration. In tests, this eliminates all fields in the field cache apart from the caches for title_sort and author_display_sort, which seem small in comparison.

Clarifications

  • I don't know if we could or should also eliminate the field caches for the sorting caches, which seems to be the lowercase field type.
  • I'm not sure if we should do anything for performing an automatic migration/re-indexing on upgrades.

Screenshots & Video

No UI changes.

Executed Tests

Manual tests as mentioned above.

Expected merging strategy

  • Prefers squash: Yes
  • Backport on branches:
    • stable-16.10.x
    • stable-16.4.x

* Configure the "string" field type with docValues="true" as in the
  default configuration. In tests, this eliminates all fields in the
  field cache apart from the caches for title_sort and
  author_display_sort, which seem small in comparison.
@tmortagne
Copy link
Member

I'm not sure if we should do anything for performing an automatic migration/re-indexing on upgrades.

I'm not sure it worth it. Those who don't have memory problems with Solr don't critically need this, and it's always annoying to have to reindex everything.

That being said, it's now (16.10.0+) much easier to trigger a re-creation of the embedded Solr core (by updating the search schema version at https://github.com/xwiki/xwiki-platform/blob/master/xwiki-platform-core/xwiki-platform-search/xwiki-platform-search-solr/xwiki-platform-search-solr-api/src/main/java/org/xwiki/search/solr/internal/EmbeddedSolr.java#L93).

@michitux michitux self-assigned this Feb 3, 2025
@michitux michitux merged commit 062dabe into xwiki:master Feb 3, 2025
2 checks passed
@michitux michitux deleted the XWIKI-22820 branch February 3, 2025 14:01
github-actions bot pushed a commit that referenced this pull request Feb 3, 2025
* Configure the "string" field type with docValues="true" as in the
  default configuration. In tests, this eliminates all fields in the
  field cache apart from the caches for title_sort and
  author_display_sort, which seem small in comparison.

(cherry picked from commit 062dabe)
github-actions bot pushed a commit that referenced this pull request Feb 3, 2025
* Configure the "string" field type with docValues="true" as in the
  default configuration. In tests, this eliminates all fields in the
  field cache apart from the caches for title_sort and
  author_display_sort, which seem small in comparison.

(cherry picked from commit 062dabe)
Copy link

github-actions bot commented Feb 3, 2025

💚 All backports created successfully

Status Branch Result
stable-16.4.x
stable-16.10.x

Questions ?

Please refer to the Backport tool documentation and see the Github Action logs for details

michitux added a commit that referenced this pull request Feb 3, 2025
* Configure the "string" field type with docValues="true" as in the
  default configuration. In tests, this eliminates all fields in the
  field cache apart from the caches for title_sort and
  author_display_sort, which seem small in comparison.

(cherry picked from commit 062dabe)
michitux added a commit that referenced this pull request Feb 3, 2025
* Configure the "string" field type with docValues="true" as in the
  default configuration. In tests, this eliminates all fields in the
  field cache apart from the caches for title_sort and
  author_display_sort, which seem small in comparison.

(cherry picked from commit 062dabe)
Sereza7 pushed a commit to Sereza7/xwiki-platform that referenced this pull request Feb 4, 2025
* Configure the "string" field type with docValues="true" as in the
  default configuration. In tests, this eliminates all fields in the
  field cache apart from the caches for title_sort and
  author_display_sort, which seem small in comparison.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants