Package org.ametys.cms.search.solr
Class NoAutoCommitUpdateClient
java.lang.Object
org.apache.solr.client.solrj.SolrClient
org.apache.solr.client.solrj.impl.ConcurrentUpdateHttp2SolrClient
org.ametys.cms.search.solr.AbstractAmetysConcurrentUpdateClient
org.ametys.cms.search.solr.NoAutoCommitUpdateClient
- All Implemented Interfaces:
Closeable,Serializable,AutoCloseable
Update
SolrClient which uses the Solr `noAutoCommit` Update Request Processor chain, so as to not trigger the autoCommit mechanism.- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.solr.client.solrj.impl.ConcurrentUpdateHttp2SolrClient
org.apache.solr.client.solrj.impl.ConcurrentUpdateHttp2SolrClient.Builder -
Field Summary
Fields inherited from class org.apache.solr.client.solrj.SolrClient
defaultCollection -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class org.ametys.cms.search.solr.AbstractAmetysConcurrentUpdateClient
add, add, add, add, add, add, add, add, add, add, addBean, addBean, addBean, addBean, addBeans, addBeans, addBeans, addBeans, addBeans, addBeans, commit, commit, commit, commit, commit, commit, deleteById, deleteById, deleteById, deleteById, deleteById, deleteById, deleteById, deleteById, deleteByQuery, deleteByQuery, deleteByQuery, deleteByQuery, handleError, onSuccess, optimize, optimize, optimize, optimize, optimize, optimize, rollback, rollbackMethods inherited from class org.apache.solr.client.solrj.impl.ConcurrentUpdateHttp2SolrClient
blockUntilFinished, close, setPollQueueTime, shutdownNowMethods inherited from class org.apache.solr.client.solrj.SolrClient
getBinder, getById, getById, getById, getById, getById, getById, getById, getById, getContext, getDefaultCollection, ping, ping, query, query, query, query, queryAndStreamResponse, queryAndStreamResponse, queryAndStreamResponse, request
-
Constructor Details
-
NoAutoCommitUpdateClient
public NoAutoCommitUpdateClient(String solrServerUrl, String login, String password, Optional<Integer> solrSocketTimeout, String collectionName, int queueSize, int threadCount, org.slf4j.Logger logger) Constructor- Parameters:
solrServerUrl- The Solr server URLlogin- The login to authenticate on the Solr apppassword- The password to authenticate on the Solr appsolrSocketTimeout- The Solr socket timeout (in millis)collectionName- The name of the collection, on which operations will be allowed. Operations on other collections will be forbidden.queueSize- The buffer size before the documents are sent to the serverthreadCount- The number of background threads used to empty the queuelogger- internal logger
-
-
Method Details
-
request
public org.apache.solr.common.util.NamedList<Object> request(org.apache.solr.client.solrj.SolrRequest request, String collection) throws org.apache.solr.client.solrj.SolrServerException, IOException - Overrides:
requestin classorg.apache.solr.client.solrj.impl.ConcurrentUpdateHttp2SolrClient- Throws:
org.apache.solr.client.solrj.SolrServerExceptionIOException
-