### CI Link

https://gradle-enterprise.elastic.co/s/oyi6h23yl6k3o/tests/:x-pack:qa:full-cluster-restart:v8.11.0%23bwcTest/org.elasticsearch.xpack.restart.CoreFullClusterRestartIT/testClusterState%20%7Bcluster=OLD%7D

### Repro line

./gradlew ':qa:full-cluster-restart:v8.11.0#bwcTest' -Dtests.class="org.elasticsearch.upgrades.FullClusterRestartIT"

### Does it reproduce?

Yes

### Applicable branches

main

### Failure history

_No response_

### Failure excerpt

This test assumes that the index created version in cluster state matches the old node version.

That is no longer true due to the introduction of `IndexVersion`

https://github.com/elastic/elasticsearch/blob/52a6820813577abcb23191d862a01e32e652ed42/qa/full-cluster-restart/src/javaRestTest/java/org/elasticsearch/upgrades/FullClusterRestartIT.java#L435-L440
qa/full-cluster-restart/src/javaRestTest/java/org/elasticsearch/upgrades/FullClusterRestartIT.java
restoreCommand.field("rename_pattern", index);
            restoreCommand.field("rename_replacement", "restored-" + index);
            restoreCommand.startObject("index_settings");
            {
                restoreCommand.field("index.soft_deletes.enabled", false);
            }
            restoreCommand.endObject();
            restoreCommand.endObject();
            Request restoreRequest = new Request("POST", "/_snapshot/repo/" + snapshot + "/_restore");
            restoreRequest.addParameter("wait_for_completion", "true");
            restoreRequest.setJsonEntity(Strings.toString(restoreCommand));
            final ResponseException error = expectThrows(ResponseException.class, () -> client().performRequest(restoreRequest));
            assertThat(error.getMessage(), containsString("cannot disable setting [index.soft_deletes.enabled] on restore"));
        }
    }
    /**
     * In 7.14 the cluster.remote.*.transport.compress setting was change from a boolean to an enum setting
     * with true/false as options. This test ensures that the old boolean setting in cluster state is
     * translated properly. This test can be removed in 9.0.
     */
    public void testTransportCompressionSetting() throws IOException {
        assumeTrue("the old transport.compress setting existed before 7.14", getOldClusterVersion().before(Version.V_7_14_0));
        assumeTrue(
            "Early versions of 6.x do not have cluster.remote* prefixed settings",
            getOldClusterVersion().onOrAfter(Version.V_7_14_0.minimumCompatibilityVersion())
        );
        if (isRunningAgainstOldCluster()) {
            final Request putSettingsRequest = new Request("PUT", "/_cluster/settings");
            try (XContentBuilder builder = jsonBuilder()) {
                builder.startObject();