SOLR-18163: Remove v2-disabling sysprop#4233
Conversation
Solr has long supported an experimental sysprop `solr.api.v2.enabled` that can be used to disable the v2 API if set to false. This has been a nice safety-valve for users, but it prevents us from doing any dog-fooding of the v2 APIs since it makes it possible for the APIs to not be available at all. The v2 APIs are maturing and would really benefit from this additional testing and feedback. For this reason, this commit removes the experimental system property and all references to v2 "optionality" in the codebase.
|
Still TODO here:
This PR is for 'main' only. But when we backport this to branch_10x, we should also put a check on startup that can log a message if the (now defunct) system property is specified, so that users can notice that this former config option is no longer actually doing anything for them. |
epugh
left a comment
There was a problem hiding this comment.
One idea... Do we need a way of flagging no longer used system properties/settings in a global way? Similar to the DeprecatedSystemPropertyMappings.properties that would loudly warn, but not break things?
I could see this being added to such a file...
I'm not going to bite that off as a part of this ticket, but it does seem like it'd be nice, generally. |
This will allow Solr and other tooling to start relying on the v2 API.
|
Actually, my warning-log in branch_10x ended up looking pretty general purpose. Essentially, EnvUtils now has a list of removed properties and the 'init' in that class will check to see if any of those "removed props" are currently set. If so, a warning is logged. If we like that general approach, we can bring it forward to 'main'. Right now that bit of code is only on branch_10x, which feels a little weird. Here's the commit, for reference: 121f8ba |
I was hoping you used EnvUtils and I think this is a great way of handling more generically. |
https://issues.apache.org/jira/browse/SOLR-18163
Description
Solr has long supported an experimental sysprop
solr.api.v2.enabledthat can be used to disable the v2 API if set to false. This has been a nice safety-valve for users, but it prevents us from doing any dog-fooding of the v2 APIs since it makes it possible for the APIs to not be available at all.The v2 APIs are maturing and would really benefit from this additional testing and feedback.
Solution
This commit removes the experimental system property and all references to v2 "optionality" in the codebase.
Tests
Modifications to a BATS test meant to test our deprecation sysprop warnings.
Checklist
Please review the following and check all that apply:
mainbranch../gradlew check.