driver-core/src/main/com/mongodb/client/model/Accumulators.java
public static <TExpression> BsonField sum(final String fieldName, final TExpression expression) {
        return accumulator("$sum", fieldName, expression);
    }
public static <TExpression> BsonField sum(final String fieldName, final TExpression expression) {
        return accumulator("$sum", fieldName, expression);
    }
Gets a field name for a $group operation representing the sum of the values of the given expression when applied to all members of
the group.

@param fieldName the field name
@param expression the expression
@param <TExpression> the expression type
@return the field
@mongodb.driver.manual reference/operator/aggregation/sum/ $sum