[ 
https://issues.apache.org/jira/browse/SOLR-17066?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17820750#comment-17820750
 ] 

ASF subversion and git services commented on SOLR-17066:
--------------------------------------------------------

Commit c5709bd4135538fffba3b2c4947dd91ff28d5750 in solr's branch 
refs/heads/main from Jason Gerlowski
[ https://gitbox.apache.org/repos/asf?p=solr.git;h=c5709bd4135 ]

SOLR-17066: Switch "LB" clients away from core URLs (#2283)

Providing a core URL String as a SolrClient's "base URL" prevents
it from communicating with other cores or making core-agnostic API
requests (e.g. node healthcheck, list cores, etc.)

This commit migrates usage of both "LB" clients away from using
raw core-URL Strings, in favor of using a new structured 'Endpoint'
class, which allows access to both the "root URL" and "collection"
separately.

This commit also updates various ref-guides and Javadoc snippets to
reflect the fact that clients now only accept "root URLs" (with a small
exception for LB clients which may use the Endpoint class, as mentioned
above).

> Deprecate and remove core URLs in HttpSolrClient and friends
> ------------------------------------------------------------
>
>                 Key: SOLR-17066
>                 URL: https://issues.apache.org/jira/browse/SOLR-17066
>             Project: Solr
>          Issue Type: Improvement
>          Components: SolrJ
>            Reporter: Jason Gerlowski
>            Priority: Major
>          Time Spent: 12.5h
>  Remaining Estimate: 0h
>
> Currently, URL-driven SolrClients can consume a base URL that either ends in 
> an API-version specific path ("/solr" for v1 APIs, "/api" for v2), or in the 
> full path to a specific core or collection ("/solr/techproducts").
> The latter option causes a number of problems in practice.  It prevents the 
> client from being used for any "admin" requests or for requests to other 
> cores or collections.  (Short of running a regex on 
> {{SolrClient.getBaseURL}}, it's hard to even tell which of these restrictions 
> a given client might have.)  And lastly, specifying such core/collection URL 
> makes it tough mix and match v1 and v2 API requests within the same client 
> (see SOLR-17044).
> We should give SolrJ users some similar way to default collection/cores 
> without any of these  downsides.  One approach would be to extend the 
> {{withDefaultCollection}} pattern currently established in 
> {{CloudHttp2SolrClient.Builder}}.
> (IMO we should also revisit the division of responsibilities between 
> SolrClient and SolrRequest implementations - maybe clients shouldn't, 
> directly at least, be holding on to request-specific settings like the 
> core/collection at all.  But that's a much larger concern that we might not 
> want to wade into here.  See SOLR-10466 for more on this topic.)



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org
For additional commands, e-mail: issues-h...@solr.apache.org

Reply via email to