[EOSC DUMP] removed not needed parameters

This commit is contained in:
Miriam Baglioni 2022-11-07 17:55:51 +01:00
parent 4e57cc22a1
commit 686f407bcd
1 changed files with 3 additions and 8 deletions

View File

@ -61,11 +61,6 @@ public class ExtendEoscResultWithOrganizationStep2 implements Serializable {
final String outputPath = parser.get("outputPath"); final String outputPath = parser.get("outputPath");
log.info("outputPath: {}", outputPath); log.info("outputPath: {}", outputPath);
final String resultClassName = parser.get("resultTableName");
log.info("resultTableName: {}", resultClassName);
Class<? extends Result> inputClazz = (Class<? extends Result>) Class.forName(resultClassName);
SparkConf conf = new SparkConf(); SparkConf conf = new SparkConf();
runWithSparkSession( runWithSparkSession(
@ -73,12 +68,12 @@ public class ExtendEoscResultWithOrganizationStep2 implements Serializable {
isSparkSessionManaged, isSparkSessionManaged,
spark -> { spark -> {
Utils.removeOutputDir(spark, outputPath); Utils.removeOutputDir(spark, outputPath);
addOrganizations(spark, inputPath, outputPath, resultPath, inputClazz); addOrganizations(spark, inputPath, outputPath, resultPath);
}); });
} }
private static <R extends Result> void addOrganizations(SparkSession spark, String inputPath, String outputPath, private static void addOrganizations(SparkSession spark, String inputPath, String outputPath,
String resultPath, Class<R> inputClazz) { String resultPath) {
Dataset<EoscResult> results = Utils Dataset<EoscResult> results = Utils
.readPath(spark, resultPath, EoscResult.class); .readPath(spark, resultPath, EoscResult.class);