private void mergeErrorStatsFrom(int distributorIndex, ContentNodeErrorStats stats, int factor) {
        var existing = statsFromDistributors.get(distributorIndex);
        var newStats = stats.statsFromDistributors.get(distributorIndex);
        if (existing == null && newStats != null && factor == 1) {
            existing = DistributorErrorStats.createEmpty();
            statsFromDistributors.put(distributorIndex, existing);
        }
        if (existing != null) {
            if (newStats != null) {
                existing.merge(newStats, factor);
            }
            if (factor == -1 && !existing.hasErrors()) {
                // Error stats are sparse, so if we have no more errors for the node, remove the entry.
                statsFromDistributors.remove(distributorIndex);
            }
        }
    }
A sparse mapping from distributors to error stats observed <em>by</em> that distributor
<em>towards</em> one particular content node (i.e. all distributor observations are for
the same content node). If no errors have been observed by a distributor, it will not
have an entry in this mapping, hence the sparseness.

@author vekterli
clustercontroller-core/src/main/java/com/yahoo/vespa/clustercontroller/core/ContentNodeErrorStats.java