Use index name rather than Index.java to lookup IndexService

This commit is contained in:
Simon Willnauer 2015-02-19 13:52:48 +01:00
parent fe2b30230f
commit 795dd8111f
1 changed files with 1 additions and 1 deletions

View File

@ -535,7 +535,7 @@ public class IndicesService extends AbstractLifecycleComponent<IndicesService> i
* @return true if the index can be deleted on this node
*/
public boolean canDeleteIndexContents(Index index, Settings indexSettings) {
final Tuple<IndexService, Injector> indexServiceInjectorTuple = this.indices.get(index);
final Tuple<IndexService, Injector> indexServiceInjectorTuple = this.indices.get(index.name());
if (IndexMetaData.isOnSharedFilesystem(indexSettings) == false) {
if (indexServiceInjectorTuple == null && nodeEnv.hasNodeFile()) {
return true;