Skip to content

Update caches-warming.adoc with a note about maxRamMB#1238

Merged
epugh merged 1 commit intoapache:mainfrom
EreMaijala:patch-1
Feb 16, 2024
Merged

Update caches-warming.adoc with a note about maxRamMB#1238
epugh merged 1 commit intoapache:mainfrom
EreMaijala:patch-1

Conversation

@EreMaijala
Copy link
Contributor

Add a note about documentCache not supporting maxRamMB setting properly.

Since Lucene's RamUsageEstimator doesn't understand the Document objects, it will default to 256 bytes. Depending on the real document size this can be wildly inaccurate and cause the cache to use several magnitudes more memory than expected.

Add a note about documentCache not supporting maxRamMB setting properly.

Since Lucene's RamUsageEstimator doesn't understand the Document objects, it will default to 256 bytes. Depending on the real document size this can be wildly inaccurate and cause the cache to use several magnitudes more memory than expected.
@EreMaijala
Copy link
Contributor Author

For reference, I had documentCache with maxRamMB="128" consume 4.9 GB of memory. A quick web search indicated that others have stumbled on this issue before as well, so a nice little note in the documentation might help someone avoid the pitfall.

@janhoy janhoy self-assigned this Apr 1, 2023
@github-actions
Copy link

This PR had no visible activity in the past 60 days, labeling it as stale. Any new activity will remove the stale label. To attract more reviewers, please tag someone or notify the dev@solr.apache.org mailing list. Thank you for your contribution!

@github-actions github-actions bot added the stale PR not updated in 60 days label Feb 16, 2024
@epugh epugh merged commit 0679644 into apache:main Feb 16, 2024
epugh pushed a commit that referenced this pull request Feb 16, 2024
Add a note about documentCache not supporting maxRamMB setting properly.

Since Lucene's RamUsageEstimator doesn't understand the Document objects, it will default to 256 bytes. Depending on the real document size this can be wildly inaccurate and cause the cache to use several magnitudes more memory than expected.
@epugh
Copy link
Contributor

epugh commented Feb 16, 2024

Thank you for the doc improvement, sorry it took so long to merge!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

stale PR not updated in 60 days

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants