-
Notifications
You must be signed in to change notification settings - Fork 674
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
SOLR-16781: Remove solrconfig.xml <lib> directives #2875
Conversation
Solr offers a number of ways for users to add JARs and resources to their classpath, including: * solr.xml <sharedLib> entries * SOLR_MODULES env-var/support * core and install-level "lib/" directories * the package manager * direct classpath modification In addition to being largely redundant with the methods above, solrconfig.xml's <lib> directive has been a pain point and source of security concerns in the past. This commit removes it from Solr 10. Still needed: - CHANGES.txt - Upgrade Notes / "Major Changes" docs - decision around vestigial "trusted configset" support
@gerlowskija how do you want to handle #2861? Should it go in first, or after? |
@gerlowskija FYI I merged and backported https://issues.apache.org/jira/browse/SOLR-17556 to clear the decks, but which may impact this a bit. I think you plan for beefing up bin/solr start -e techproducts is a "good thing". |
Sorry - missed this comment the other day. I'm glad I didn't prevent you from merging 2861 - I'm 👍 to incorporate any fallout into this PR. |
Alright - I've fixed merge conflicts, and tested out the examples, so this should be good to merge shortly. Thanks for the reviews all! I've created a corresponding change for branch_9x that will disable |
@@ -37,8 +37,6 @@ | |||
|
|||
<luceneMatchVersion>${tests.luceneMatchVersion:LATEST}</luceneMatchVersion> | |||
|
|||
<lib dir="${solr.install.dir:../../../..}/modules/ltr/lib/" regex=".*\.jar" /> |
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.
Maybe this file doesn't need to exist at all?
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.
Good catch - removed!
One thing we'll probably want/need to come up with a better story around is model-serving. Several places in our docs described using |
Yeah, it should, but there is also the |
Alright - merged! Thanks all for the reviews! We'll still need to decide whether to remove the last remnants of the "trusted" configset code, which this PR mostly leaves in tact since several components (e.g. ScriptUpdateProcessorFactory, XSLTUpdateRequestHandler) still rely on this distinction even with the My vote would be to tear it out. All the places it's still used require the toggling of a module at startup ( |
+1 |
https://issues.apache.org/jira/browse/SOLR-16781
Description
Solr offers a number of ways for users to add JARs and resources to their classpath, including:
In addition to being largely redundant with the methods above, solrconfig.xml's directive has been a pain point and source of security concerns in the past.
Solution
This commit removes references and support from 'main'. Most of the functional changes live in SolrConfig.java, where we now check for tags only to log out a warning about them being no longer supported. The remainder of the PR consists of updates to our ref-guide, to recommend other means of adding JARs to Solr's classpath. Most of these are for first-party modules, which can use the SOLR_MODULES system.
This PR is only intended for main: I'll open a separate more forgiving PR for branch_9x that disables
<lib>
by default but allows it to be re-enabled via sysprop/envvar.Still TODO:
Tests
Some modifications made to existing tests to ensure that tags no longer function (particularly TestConfigSetsAPI).
Checklist
Please review the following and check all that apply:
main
branch../gradlew check
.