### CI Link

https://gradle-enterprise.elastic.co/s/4accu24s4cbyc

### Repro line

./gradlew ':server:internalClusterTest' --tests "org.elasticsearch.get.ShardMultiGetFomTranslogActionIT.testShardMultiGetFromTranslog" -Dtests.seed=AC01D0C25C12539E -Dtests.locale=hr-HR -Dtests.timezone=Africa/Windhoek -Druntime.java=20

### Does it reproduce?

Yes

### Applicable branches

main

### Failure history

Test was introduced today via https://github.com/elastic/elasticsearch/pull/96492

### Failure excerpt

```java
org.elasticsearch.get.ShardMultiGetFomTranslogActionIT > testShardMultiGetFromTranslog FAILED
    java.lang.AssertionError
        at __randomizedtesting.SeedInfo.seed([AC01D0C25C12539E:D5637AF36B6B21E3]:0)
        at org.junit.Assert.fail(Assert.java:86)
        at org.junit.Assert.assertTrue(Assert.java:41)
        at org.junit.Assert.assertNotNull(Assert.java:712)
        at org.junit.Assert.assertNotNull(Assert.java:722)
        at org.elasticsearch.get.ShardMultiGetFomTranslogActionIT.testShardMultiGetFromTranslog(ShardMultiGetFomTranslogActionIT.java:105)
```


server/src/internalClusterTest/java/org/elasticsearch/get/ShardMultiGetFomTranslogActionIT.java
assertThat(getLocations(multiGetShardResponse).size(), equalTo(1));
        assertTrue(getFailures(multiGetShardResponse).stream().allMatch(Objects::isNull));
        getResponses = getResponses(multiGetShardResponse);
        assertThat(getResponses.size(), equalTo(1));
        assertNotNull(getResponses.get(0));
        assertThat(getResponses.get(0).getId(), equalTo(indexResponse.getId()));
        assertThat(getResponses.get(0).getVersion(), equalTo(indexResponse.getVersion()));
        assertThat(response.segmentGeneration(), equalTo(-1L));
        
        refresh("test");
        response = getFromTranslog(indexOrAlias(), List.of(indexResponse.getId()));
        multiGetShardResponse = response.multiGetShardResponse();
        assertThat(getLocations(multiGetShardResponse).size(), equalTo(1));
        assertTrue(getFailures(multiGetShardResponse).stream().allMatch(Objects::isNull));
        assertTrue(
            "after a refresh we should not be able to get from translog",
            getResponses(multiGetShardResponse).stream().allMatch(Objects::isNull)
        );
        assertThat(response.segmentGeneration(), equalTo(-1L));
        
        
        client().prepareIndex("test").setSource("field1", "value3").get();
        refresh("test");
        refresh("test");
        
        client().prepareIndex("test").setSource("field1", "value4").get();
        response = getFromTranslog(indexOrAlias(), List.of("non-existent"));
        multiGetShardResponse = response.multiGetShardResponse();
        assertThat(getLocations(multiGetShardResponse).size(), equalTo(1));
        assertThat(getFailures(multiGetShardResponse).size(), equalTo(1));