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

SOLR-17042: Remove V2RequestSupport interface #2028

Conversation

gerlowskija
Copy link
Contributor

@gerlowskija gerlowskija commented Oct 19, 2023

https://issues.apache.org/jira/browse/SOLR-17042

Description

Initially intended as a way to allow dog-fooding of v2 APIs by converting v1 requests into their v2 counterparts, V2RequestSupport never received the adoption it needed to get traction within the codebase. It made most sense in a world where all v2 APIs had clear v1 counterparts, and was only ever implemented for a small set of "collection admin" APIs at the peak of its adoption.

It currently has 0 implementations and should be removed from Solr, as it's largely been superceded by the newer approach of generating distinct v2 SolrRequest implementations from our OAS.

Solution

This commit removes the V2RequestSupport interface and two associated SolrRequest methods on the main branch. (Upon merging, a corresponding set of deprecation notices will be added to branch_9x to keep this in line with our backcompat policy.)

Tests

Existing tests continue to pass.

Checklist

Please review the following and check all that apply:

  • I have reviewed the guidelines for How to Contribute and my code conforms to the standards described there to the best of my ability.
  • I have created a Jira issue and added the issue ID to my pull request title.
  • I have given Solr maintainers access to contribute to my PR branch. (optional but recommended)
  • I have developed this patch against the main branch.
  • I have run ./gradlew check.
  • I have added documentation for the Reference Guide

Initially intended as a way to allow dog-fooding of v2 APIs by
converting v1 requests into their v2 counterparts, V2RequestSupport
never received the adoption it needed to get traction within the
codebase.  It was only ever implemented for a small set of "collection
admin" APIs, and was superceded by our current approach in SolrJ of
generating v2 SolrRequest implementations from our "OAS".

This commit removes the interface, and two associated SolrRequest
methods, from SolrJ.
@epugh
Copy link
Contributor

epugh commented Oct 19, 2023

Nice bit of clean up. Makes me sad we can't just remove it altogether if no api's are currently using it....

@gerlowskija
Copy link
Contributor Author

Makes me sad we can't just remove it altogether if no api's are currently using it....

Yeah, agreed. But the cost is pretty low, so it's not a huge deal either way 🤷

This is the first of a few improvements I have in mind to how SolrJ inspects and decides how to route requests. Obviously there'll be a gap between 9.x and 10 for backcompat, but the cumulative effect on main is gonna be really nice I hope. Pretty excited

@gerlowskija gerlowskija merged commit b57b563 into apache:main Oct 23, 2023
3 checks passed
@gerlowskija gerlowskija deleted the SOLR-17042-remove-v2requestsupport-interface branch October 23, 2023 00:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants