Search in sources :

Example 1 with CachingSearcher

use of com.yahoo.prelude.searcher.CachingSearcher in project vespa by vespa-engine.

the class CachingSearcherTestCase method setUp.

@Before
public void setUp() throws Exception {
    hits = new DocumentSourceSearcher();
    QrSearchersConfig config = new QrSearchersConfig(new QrSearchersConfig.Builder().com(new QrSearchersConfig.Com.Builder().yahoo(new QrSearchersConfig.Com.Yahoo.Builder().prelude(new QrSearchersConfig.Com.Yahoo.Prelude.Builder().searcher(new QrSearchersConfig.Com.Yahoo.Prelude.Searcher.Builder().CachingSearcher(new QrSearchersConfig.Com.Yahoo.Prelude.Searcher.CachingSearcher.Builder().cachesizemegabytes(10).maxentrysizebytes(5 * 1024 * 1024).timetoliveseconds(86400)))))));
    CachingSearcher cache = new CachingSearcher(config, Statistics.nullImplementation);
    searchChain = new Chain<>(cache, hits);
}
Also used : CachingSearcher(com.yahoo.prelude.searcher.CachingSearcher) QrSearchersConfig(com.yahoo.container.QrSearchersConfig) DocumentSourceSearcher(com.yahoo.prelude.searcher.DocumentSourceSearcher) Before(org.junit.Before)

Aggregations

QrSearchersConfig (com.yahoo.container.QrSearchersConfig)1 CachingSearcher (com.yahoo.prelude.searcher.CachingSearcher)1 DocumentSourceSearcher (com.yahoo.prelude.searcher.DocumentSourceSearcher)1 Before (org.junit.Before)1