Several tests failed in the same way:


- [NoOrdinalsStringFieldDataTests » classMethod](https://gradle-enterprise.elastic.co/s/criyecvbvjcqy/tests/:server:test/org.elasticsearch.index.fielddata.NoOrdinalsStringFieldDataTests)
- [NoOrdinalsStringFieldDataTests » classMethod](https://gradle-enterprise.elastic.co/s/criyecvbvjcqy/tests/:server:test/org.elasticsearch.index.fielddata.NoOrdinalsStringFieldDataTests)
- [SortedSetDVStringFieldDataTests » classMethod](https://gradle-enterprise.elastic.co/s/criyecvbvjcqy/tests/:server:test/org.elasticsearch.index.fielddata.SortedSetDVStringFieldDataTests)
- [SortedSetDVStringFieldDataTests » classMethod](https://gradle-enterprise.elastic.co/s/criyecvbvjcqy/tests/:server:test/org.elasticsearch.index.fielddata.SortedSetDVStringFieldDataTests)
- [PagedBytesStringFieldDataTests » classMethod](https://gradle-enterprise.elastic.co/s/criyecvbvjcqy/tests/:server:test/org.elasticsearch.index.fielddata.PagedBytesStringFieldDataTests)
- [PagedBytesStringFieldDataTests » classMethod](https://gradle-enterprise.elastic.co/s/criyecvbvjcqy/tests/:server:test/org.elasticsearch.index.fielddata.PagedBytesStringFieldDataTests)

**Build scan:**
https://gradle-enterprise.elastic.co/s/criyecvbvjcqy/tests/:server:test/org.elasticsearch.index.fielddata.NoOrdinalsStringFieldDataTests

**Reproduction line:**
```
./gradlew ':server:test' --tests "org.elasticsearch.index.fielddata.NoOrdinalsStringFieldDataTests" -Dtests.seed=6970E66CD7B23E6C -Dtests.locale=en-US -Dtests.timezone=Etc/UTC -Druntime.java=20
```

**Applicable branches:**
main

**Reproduces locally?:**
Yes

**Failure history:**
https://gradle-enterprise.elastic.co/scans/tests?tests.container=org.elasticsearch.index.fielddata.NoOrdinalsStringFieldDataTests&tests.test=classMethod

**Failure excerpt:**
```
com.carrotsearch.randomizedtesting.ThreadLeakError: 2 threads leaked from SUITE scope at org.elasticsearch.index.fielddata.NoOrdinalsStringFieldDataTests: 
   1) Thread[id=499, name=LuceneTestCase-44-thread-2, state=WAITING, group=TGRP-NoOrdinalsStringFieldDataTests]
        at java.base/jdk.internal.misc.Unsafe.park(Native Method)
        at java.base/java.util.concurrent.locks.LockSupport.park(LockSupport.java:371)
        at java.base/java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionNode.block(AbstractQueuedSynchronizer.java:519)
        at java.base/java.util.concurrent.ForkJoinPool.unmanagedBlock(ForkJoinPool.java:3780)
        at java.base/java.util.concurrent.ForkJoinPool.managedBlock(ForkJoinPool.java:3725)
        at java.base/java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:1707)
        at java.base/java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:435)
        at java.base/java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1070)
        at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1130)
        at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
        at java.base/java.lang.Thread.run(Thread.java:1623)
   2) Thread[id=498, name=LuceneTestCase-44-thread-1, state=WAITING, group=TGRP-NoOrdinalsStringFieldDataTests]
        at java.base/jdk.internal.misc.Unsafe.park(Native Method)
        at java.base/java.util.concurrent.locks.LockSupport.park(LockSupport.java:371)
        at java.base/java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionNode.block(AbstractQueuedSynchronizer.java:519)
        at java.base/java.util.concurrent.ForkJoinPool.unmanagedBlock(ForkJoinPool.java:3780)
        at java.base/java.util.concurrent.ForkJoinPool.managedBlock(ForkJoinPool.java:3725)
        at java.base/java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:1707)
        at java.base/java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:435)
        at java.base/java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1070)
        at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1130)
        at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:642)
        at java.base/java.lang.Thread.run(Thread.java:1623)

  at __randomizedtesting.SeedInfo.seed([6970E66CD7B23E6C]:0)

```
server/src/test/java/org/elasticsearch/index/fielddata/AbstractStringFieldDataTestCase.java
addField(d, "_id", "8");
        addField(d, "value", "!08");
        addField(d, "value", "!09");
        addField(d, "value", "!10");
        writer.addDocument(d);
    }
    public void testActualMissingValue() throws IOException {
        testActualMissingValue(false);
    }
    public void testActualMissingValueReverse() throws IOException {
        testActualMissingValue(true);
    }
    public void testActualMissingValue(boolean reverse) throws IOException {
        
        final String[] values = new String[randomIntBetween(2, 30)];
        for (int i = 1; i < values.length; ++i) {
            values[i] = TestUtil.randomUnicodeString(random());
        }
        final int numDocs = scaledRandomIntBetween(10, 3072);
        for (int i = 0; i < numDocs; ++i) {
            final String value = RandomPicks.randomFrom(random(), values);
            if (value == null) {
                writer.addDocument(new Document());
            } else {
                Document d = new Document();
                addField(d, "value", value);
                writer.addDocument(d);
            }
            if (randomInt(10) == 0) {
                writer.commit();