[SPARK-3418] Fixed MiMa compatibility issues (excluded from check)