diff --git a/muted-tests.yml b/muted-tests.yml index 3719c20194b9b..4e911448969bf 100644 --- a/muted-tests.yml +++ b/muted-tests.yml @@ -327,9 +327,6 @@ tests: - class: org.elasticsearch.xpack.autoscaling.storage.ReactiveStorageIT method: testScaleWhileShrinking issue: https://github.com/elastic/elasticsearch/issues/122119 -- class: org.elasticsearch.xpack.searchablesnapshots.FrozenSearchableSnapshotsIntegTests - method: testCreateAndRestorePartialSearchableSnapshot - issue: https://github.com/elastic/elasticsearch/issues/122693 - class: org.elasticsearch.search.basic.SearchWithRandomDisconnectsIT method: testSearchWithRandomDisconnects issue: https://github.com/elastic/elasticsearch/issues/122707 diff --git a/x-pack/plugin/searchable-snapshots/src/main/java/org/elasticsearch/xpack/searchablesnapshots/cache/full/CacheService.java b/x-pack/plugin/searchable-snapshots/src/main/java/org/elasticsearch/xpack/searchablesnapshots/cache/full/CacheService.java index a02c32cd56d94..dee6fc7241d53 100644 --- a/x-pack/plugin/searchable-snapshots/src/main/java/org/elasticsearch/xpack/searchablesnapshots/cache/full/CacheService.java +++ b/x-pack/plugin/searchable-snapshots/src/main/java/org/elasticsearch/xpack/searchablesnapshots/cache/full/CacheService.java @@ -245,8 +245,8 @@ private void ensureLifecycleStarted() { final Lifecycle.State state = lifecycleState(); assert state != Lifecycle.State.INITIALIZED : state; if (state != Lifecycle.State.STARTED) { - if (state == Lifecycle.State.STOPPED) { - throw new AlreadyClosedException("Failed to read data from cache: cache service is stopped"); + if (state == Lifecycle.State.STOPPED || state == Lifecycle.State.CLOSED) { + throw new AlreadyClosedException("Failed to read data from cache: cache service is [" + state + ']'); } else { throw new IllegalStateException("Failed to read data from cache: cache service is not started [" + state + "]"); }