### 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
mappingsAndSettings.startObject("settings");
                mappingsAndSettings.field("number_of_shards", 1);
                mappingsAndSettings.field("number_of_replicas", 0);
                mappingsAndSettings.endObject();
            }
            mappingsAndSettings.endObject();
            Request createTemplate = new Request("PUT", "/_template/template_1");
            createTemplate.setJsonEntity(Strings.toString(mappingsAndSettings));
            createTemplate.setOptions(expectWarnings(RestPutIndexTemplateAction.DEPRECATION_WARNING));
            client().performRequest(createTemplate);
            client().performRequest(new Request("PUT", "/" + index));
        }
        
        Map<String, Object> clusterState = entityAsMap(client().performRequest(new Request("GET", "/_cluster/state")));
        
        String numberOfShards = (String) XContentMapValues.extractValue(
            "metadata.templates.template_1.settings.index.number_of_shards",
            clusterState
        );
        assertEquals("1", numberOfShards);
        String numberOfReplicas = (String) XContentMapValues.extractValue(
            "metadata.templates.template_1.settings.index.number_of_replicas",
            clusterState
        );
        assertEquals("0", numberOfReplicas);
        
        numberOfShards = (String) XContentMapValues.extractValue(
            "metadata.indices." + index + ".settings.index.number_of_shards",
            clusterState
        );