Reputation: 41
What is Replacement for
HttpSolrServer solrServer = new HttpSolrServer(builder.build().toString());
Upvotes: 2
Views: 2489
Reputation: 11
Use below for Solrj 9.x
SolrClient client = new Http2SolrClient.Builder("http://localhost:8983/solr/Collection1").build()
Upvotes: 1
Reputation: 1668
This is one solution:
SolrClient solrServer = new HttpSolrClient.Builder(solrLocation).build();
Upvotes: 2
Reputation: 69440
As the documentation says:
Deprecated. Use HttpSolrClient
@Deprecated public class HttpSolrServer extends HttpSolrClient
HttpSolrClient solrServer = new HttpSolrClient (builder.build().toString());
Upvotes: 1