Search in sources :

Example 11 with CoreAdminHandler

use of org.apache.solr.handler.admin.CoreAdminHandler in project SearchServices by Alfresco.

the class AbstractAlfrescoSolrTests method reindexTransactionId.

/**
 * Maintenance method
 * @param txnId
 * @throws Exception
 */
public void reindexTransactionId(long txnId) throws Exception {
    CoreAdminHandler admin = h.getCoreContainer().getMultiCoreHandler();
    SolrQueryResponse resp = new SolrQueryResponse();
    admin.handleRequestBody(req(CoreAdminParams.ACTION, "REINDEX", CoreAdminParams.NAME, h.getCore().getName(), "txid", Long.toString(txnId)), resp);
}
Also used : SolrQueryResponse(org.apache.solr.response.SolrQueryResponse) CoreAdminHandler(org.apache.solr.handler.admin.CoreAdminHandler)

Example 12 with CoreAdminHandler

use of org.apache.solr.handler.admin.CoreAdminHandler in project SearchServices by Alfresco.

the class AbstractAlfrescoSolrTests method reindexAclId.

/**
 * Maintenance method
 * @param aclId
 * @throws Exception
 */
public void reindexAclId(long aclId) throws Exception {
    CoreAdminHandler admin = h.getCoreContainer().getMultiCoreHandler();
    SolrQueryResponse resp = new SolrQueryResponse();
    admin.handleRequestBody(req(CoreAdminParams.ACTION, "REINDEX", CoreAdminParams.NAME, h.getCore().getName(), "aclid", Long.toString(aclId)), resp);
}
Also used : SolrQueryResponse(org.apache.solr.response.SolrQueryResponse) CoreAdminHandler(org.apache.solr.handler.admin.CoreAdminHandler)

Example 13 with CoreAdminHandler

use of org.apache.solr.handler.admin.CoreAdminHandler in project SearchServices by Alfresco.

the class AbstractAlfrescoSolrTests method purgeTransactionId.

// Maintenance method
public void purgeTransactionId(long txnId) throws Exception {
    CoreAdminHandler admin = h.getCoreContainer().getMultiCoreHandler();
    SolrQueryResponse resp = new SolrQueryResponse();
    admin.handleRequestBody(req(CoreAdminParams.ACTION, "PURGE", CoreAdminParams.NAME, h.getCore().getName(), "txid", Long.toString(txnId)), resp);
}
Also used : SolrQueryResponse(org.apache.solr.response.SolrQueryResponse) CoreAdminHandler(org.apache.solr.handler.admin.CoreAdminHandler)

Example 14 with CoreAdminHandler

use of org.apache.solr.handler.admin.CoreAdminHandler in project SearchServices by Alfresco.

the class AbstractAlfrescoSolrTests method reindexNodeId.

public void reindexNodeId(long nodeId) throws Exception {
    CoreAdminHandler admin = h.getCoreContainer().getMultiCoreHandler();
    SolrQueryResponse resp = new SolrQueryResponse();
    admin.handleRequestBody(req(CoreAdminParams.ACTION, "REINDEX", CoreAdminParams.NAME, h.getCore().getName(), "nodeid", Long.toString(nodeId)), resp);
}
Also used : SolrQueryResponse(org.apache.solr.response.SolrQueryResponse) CoreAdminHandler(org.apache.solr.handler.admin.CoreAdminHandler)

Example 15 with CoreAdminHandler

use of org.apache.solr.handler.admin.CoreAdminHandler in project SearchServices by Alfresco.

the class AbstractAlfrescoSolrTests method indexAclId.

/**
 * @param aclId
 * @throws Exception
 */
public void indexAclId(long aclId) throws Exception {
    CoreAdminHandler admin = h.getCoreContainer().getMultiCoreHandler();
    SolrQueryResponse resp = new SolrQueryResponse();
    admin.handleRequestBody(req(CoreAdminParams.ACTION, "INDEX", CoreAdminParams.NAME, h.getCore().getName(), "aclid", Long.toString(aclId)), resp);
}
Also used : SolrQueryResponse(org.apache.solr.response.SolrQueryResponse) CoreAdminHandler(org.apache.solr.handler.admin.CoreAdminHandler)

Aggregations

CoreAdminHandler (org.apache.solr.handler.admin.CoreAdminHandler)20 SolrQueryResponse (org.apache.solr.response.SolrQueryResponse)15 IOException (java.io.IOException)3 SolrException (org.apache.solr.common.SolrException)3 CollectionsHandler (org.apache.solr.handler.admin.CollectionsHandler)3 File (java.io.File)2 ArrayList (java.util.ArrayList)2 HashMap (java.util.HashMap)2 Map (java.util.Map)2 ExecutionException (java.util.concurrent.ExecutionException)2 ExecutorService (java.util.concurrent.ExecutorService)2 Future (java.util.concurrent.Future)2 CoreContainer (org.apache.solr.core.CoreContainer)2 InfoHandler (org.apache.solr.handler.admin.InfoHandler)2 SolrQueryRequest (org.apache.solr.request.SolrQueryRequest)2 UpdateShardHandler (org.apache.solr.update.UpdateShardHandler)2 DefaultSolrThreadFactory (org.apache.solr.util.DefaultSolrThreadFactory)2 CharacterCodingException (java.nio.charset.CharacterCodingException)1 Path (java.nio.file.Path)1 Collections.singletonList (java.util.Collections.singletonList)1