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

solrconfig.xml is using deprecated cache implementation #8325

Closed
Kris-LIBIS opened this issue Dec 23, 2021 · 8 comments
Closed

solrconfig.xml is using deprecated cache implementation #8325

Kris-LIBIS opened this issue Dec 23, 2021 · 8 comments
Labels
Component: Code Infrastructure formerly "Feature: Code Infrastructure" User Role: Sysadmin Installs, upgrades, and configures the system, connects via ssh
Projects

Comments

@Kris-LIBIS
Copy link
Contributor

Kris-LIBIS commented Dec 23, 2021

What steps does it take to reproduce the issue?
Install Dataverse with latest 8.x (currently 8.11.1) version

  • When does this issue occur?
    Whenever Solr index search is triggered

  • Which page(s) does it occurs on?
    Dataverse index page

  • What happens?
    Dataverse index page shows empty list. Solr logging dumps exception with error message:

Using join queries with synchronous filterCache is not supported! Details can be found in Solr Reference Guide under 'query-settings-in-solrconfig'.
  • To whom does it occur (all users, curators, superusers)?
    everybody ?

  • What did you expect to happen?
    Dataverse index page should list all published collections and datasets

Which version of Dataverse are you using?
5.9, but is expected to happen on any Dataverse version using latest Solr.

Any related open or closed issues to this bug report?
Log4J vulnerability is the reason I wanted to update the Solr version as the vulnerability is properly solved in the latest Solr version (docker image).

Screenshots:

No matter the issue, screenshots are always welcome.

To add a screenshot, please use one of the following formats and/or methods described here:

@Kris-LIBIS
Copy link
Contributor Author

FYI: I fixed it in my local installation by modifying the solrconfig.xml:

replacing in all cache configurations class="solr.FastLRUCache" or class="solr.LRUCache" with async="true"

@poikilotherm
Copy link
Contributor

poikilotherm commented Dec 23, 2021

This is related to #7662 and #8320

@minhd
Copy link

minhd commented Feb 2, 2022

solr.FastLRUCache or the older solr.LRUCache seems to not support the async property.

I managed to get over this issue by switching the filterCache class to the recommended solr.CaffeineCache as documented here https://solr.apache.org/guide/8_11/query-settings-in-solrconfig.html#cache-implementations

@poikilotherm
Copy link
Contributor

Thx @minhd I'll take a look and maybe add a transformation for #8320

@Kris-LIBIS
Copy link
Contributor Author

I just removed the class attribute and let Solr choose the default class (which is CaffeineCache as of Solr 8.3). I don't think the async=true is strictly necessary as that is the default for CaffeineCache. So just removing the class attribute worked fine for me.

@poikilotherm
Copy link
Contributor

Note to self:

Creating the solrconfig.xml from scratch via XSLT makes us use the new default cache implementation, as the class attribute isn't present in newer versions. It's good to know it defaults to CaffeineCache in Solr 8.3+, as this isn't stated within the docs (it's only announced to be default in Solr 9.0)

async=true is the default for Caffeine. This is very important, as we use joins etc.

If your queries include child documents or join queries, then async cache must be enabled to function properly

@pdurbin
Copy link
Member

pdurbin commented Oct 1, 2022

I don't think the async=true is strictly necessary as that is the default for CaffeineCache. So just removing the class attribute worked fine for me.

Should we just do that? @Kris-LIBIS do you want to make a PR?

@poikilotherm are you already addressing this in #8320?

We wouldn't want to duplicate effort. 😄

@pdurbin pdurbin added Component: Code Infrastructure formerly "Feature: Code Infrastructure" User Role: Sysadmin Installs, upgrades, and configures the system, connects via ssh labels Oct 9, 2022
@pdurbin pdurbin added this to Needs Reproducing in pdurbin Oct 9, 2022
@pdurbin
Copy link
Member

pdurbin commented Oct 8, 2023

We upgraded to Solr 9 in this PR:

We started over with a vanilla Solr 9 solrconfig.xml so I assume this problem has gone away. Closing, but if this is still an issue, please let us know!

@pdurbin pdurbin closed this as completed Oct 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Code Infrastructure formerly "Feature: Code Infrastructure" User Role: Sysadmin Installs, upgrades, and configures the system, connects via ssh
Projects
pdurbin
Needs Reproducing
Development

Successfully merging a pull request may close this issue.

4 participants