Skip to content

Commit

Permalink
Core: Remove DocSetCache.
Browse files Browse the repository at this point in the history
This class was unused.

Close #7582
  • Loading branch information
jpountz authored and areek committed Sep 8, 2014
1 parent d643873 commit ed8906b
Show file tree
Hide file tree
Showing 13 changed files with 3 additions and 403 deletions.
11 changes: 1 addition & 10 deletions src/main/java/org/elasticsearch/index/cache/IndexCache.java
Expand Up @@ -29,7 +29,6 @@
import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.index.AbstractIndexComponent;
import org.elasticsearch.index.Index;
import org.elasticsearch.index.cache.docset.DocSetCache;
import org.elasticsearch.index.cache.filter.FilterCache;
import org.elasticsearch.index.cache.fixedbitset.FixedBitSetFilterCache;
import org.elasticsearch.index.cache.query.parser.QueryParserCache;
Expand All @@ -42,17 +41,15 @@ public class IndexCache extends AbstractIndexComponent implements CloseableCompo

private final FilterCache filterCache;
private final QueryParserCache queryParserCache;
private final DocSetCache docSetCache;
private final FixedBitSetFilterCache fixedBitSetFilterCache;

private ClusterService clusterService;

@Inject
public IndexCache(Index index, @IndexSettings Settings indexSettings, FilterCache filterCache, QueryParserCache queryParserCache, DocSetCache docSetCache, FixedBitSetFilterCache fixedBitSetFilterCache) {
public IndexCache(Index index, @IndexSettings Settings indexSettings, FilterCache filterCache, QueryParserCache queryParserCache, FixedBitSetFilterCache fixedBitSetFilterCache) {
super(index, indexSettings);
this.filterCache = filterCache;
this.queryParserCache = queryParserCache;
this.docSetCache = docSetCache;
this.fixedBitSetFilterCache = fixedBitSetFilterCache;
}

Expand All @@ -68,10 +65,6 @@ public FilterCache filter() {
return filterCache;
}

public DocSetCache docSet() {
return this.docSetCache;
}

public QueryParserCache queryParserCache() {
return this.queryParserCache;
}
Expand All @@ -80,7 +73,6 @@ public QueryParserCache queryParserCache() {
public void close() throws ElasticsearchException {
filterCache.close();
queryParserCache.close();
docSetCache.clear("close");
fixedBitSetFilterCache.close();
if (clusterService != null) {
clusterService.remove(this);
Expand All @@ -90,7 +82,6 @@ public void close() throws ElasticsearchException {
public void clear(String reason) {
filterCache.clear(reason);
queryParserCache.clear();
docSetCache.clear(reason);
fixedBitSetFilterCache.clear(reason);
}

Expand Down
Expand Up @@ -21,7 +21,6 @@

import org.elasticsearch.common.inject.AbstractModule;
import org.elasticsearch.common.settings.Settings;
import org.elasticsearch.index.cache.docset.DocSetCacheModule;
import org.elasticsearch.index.cache.filter.FilterCacheModule;
import org.elasticsearch.index.cache.fixedbitset.FixedBitSetFilterCacheModule;
import org.elasticsearch.index.cache.query.parser.QueryParserCacheModule;
Expand All @@ -41,7 +40,6 @@ public IndexCacheModule(Settings settings) {
protected void configure() {
new FilterCacheModule(settings).configure(binder());
new QueryParserCacheModule(settings).configure(binder());
new DocSetCacheModule(settings).configure(binder());
new FixedBitSetFilterCacheModule(settings).configure(binder());

bind(IndexCache.class).asEagerSingleton();
Expand Down

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

Expand Up @@ -31,10 +31,9 @@
import org.elasticsearch.common.text.StringText;
import org.elasticsearch.common.util.BigArrays;
import org.elasticsearch.index.analysis.AnalysisService;
import org.elasticsearch.index.cache.docset.DocSetCache;
import org.elasticsearch.index.cache.filter.FilterCache;
import org.elasticsearch.index.engine.Engine;
import org.elasticsearch.index.cache.fixedbitset.FixedBitSetFilterCache;
import org.elasticsearch.index.engine.Engine;
import org.elasticsearch.index.fielddata.IndexFieldDataService;
import org.elasticsearch.index.fieldvisitor.JustSourceFieldsVisitor;
import org.elasticsearch.index.mapper.FieldMapper;
Expand Down Expand Up @@ -455,11 +454,6 @@ public FixedBitSetFilterCache fixedBitSetFilterCache() {
return indexService.fixedBitSetFilterCache();
}

@Override
public DocSetCache docSetCache() {
return indexService.cache().docSet();
}

@Override
public long timeoutInMillis() {
return -1;
Expand Down
Expand Up @@ -28,7 +28,6 @@
import org.elasticsearch.cache.recycler.PageCacheRecycler;
import org.elasticsearch.common.util.BigArrays;
import org.elasticsearch.index.analysis.AnalysisService;
import org.elasticsearch.index.cache.docset.DocSetCache;
import org.elasticsearch.index.cache.filter.FilterCache;
import org.elasticsearch.index.cache.fixedbitset.FixedBitSetFilterCache;
import org.elasticsearch.index.fielddata.IndexFieldDataService;
Expand Down Expand Up @@ -336,11 +335,6 @@ public FixedBitSetFilterCache fixedBitSetFilterCache() {
return context.fixedBitSetFilterCache();
}

@Override
public DocSetCache docSetCache() {
return context.docSetCache();
}

@Override
public IndexFieldDataService fieldData() {
return context.fieldData();
Expand Down

0 comments on commit ed8906b

Please sign in to comment.