Search in sources :

Example 1 with FaultTolerantIndexingExceptionHandler

use of cz.mzk.recordmanager.server.solr.FaultTolerantIndexingExceptionHandler in project RecordManager2 by moravianlibrary.

the class AbstractSolrTest method createEmbeddedSolrServer.

@BeforeMethod
protected void createEmbeddedSolrServer() throws Exception {
    server.deleteByQuery("*:*");
    server.commit();
    resetToNice(solrServerFactory);
    SolrIndexingExceptionHandler handler = new FaultTolerantIndexingExceptionHandler();
    expect(solrServerFactory.create(eq(SOLR_URL), anyObject(Mode.class), anyObject(SolrIndexingExceptionHandler.class))).andReturn(new SolrServerFacadeImpl(server, handler)).anyTimes();
    expect(solrServerFactory.create(eq(SOLR_URL))).andReturn(new SolrServerFacadeImpl(server, handler)).anyTimes();
    replay(solrServerFactory);
}
Also used : SolrIndexingExceptionHandler(cz.mzk.recordmanager.server.solr.SolrIndexingExceptionHandler) SolrServerFacadeImpl(cz.mzk.recordmanager.server.solr.SolrServerFacadeImpl) FaultTolerantIndexingExceptionHandler(cz.mzk.recordmanager.server.solr.FaultTolerantIndexingExceptionHandler) BeforeMethod(org.testng.annotations.BeforeMethod)

Aggregations

FaultTolerantIndexingExceptionHandler (cz.mzk.recordmanager.server.solr.FaultTolerantIndexingExceptionHandler)1 SolrIndexingExceptionHandler (cz.mzk.recordmanager.server.solr.SolrIndexingExceptionHandler)1 SolrServerFacadeImpl (cz.mzk.recordmanager.server.solr.SolrServerFacadeImpl)1 BeforeMethod (org.testng.annotations.BeforeMethod)1