With the backport of TDigest, the build started failing compiling with Java 20 with the following error:

```
> Task :libs:elasticsearch-tdigest:compileJava FAILED
../elasticsearch/libs/tdigest/src/main/java/org/elasticsearch/tdigest/SortingDigest.java:57: warning: [lossy-conversions] implicit cast from long to int in compound assignment is possibly lossy
            valuesToAddCount += other.size();
                                          ^
error: warnings found and -Werror specified
1 error
1 warning

```
Java 20 is more picky about lossy conversions,

libs/tdigest/src/main/java/org/elasticsearch/tdigest/SortingDigest.java
isSorted = false;
        max = Math.max(max, x);
        min = Math.min(min, x);
    }
    @Override
    public void add(List<? extends TDigest> others) {
        int valuesToAddCount = 0;
        for (TDigest other : others) {
            valuesToAddCount += other.size();
        }
        values.ensureCapacity(valuesToAddCount + values.size());
        for (TDigest other : others) {
            for (Centroid centroid : other.centroids()) {
                add(centroid.mean(), centroid.count());
            }
        }
    }
    @Override
    public void compress() {
        if (isSorted == false) {
            Collections.sort(values);
            isSorted = true;
        }
    }
    @Override
    public long size() {
        return values.size();
    }
    @Override
    public double cdf(double x) {