diff --git a/data-discovery/pom.xml b/data-discovery/pom.xml index 3f192d2c67ea2199e3cb65236135745332ca1961..b8b1f6110ab6f68afd484955bc2a34a2cad810dd 100644 --- a/data-discovery/pom.xml +++ b/data-discovery/pom.xml @@ -4,14 +4,13 @@ <groupId>vlkb</groupId> <artifactId>vlkb-siav2</artifactId> <packaging>war</packaging> - <version>1.6.5</version> - <name>psearch Maven Webapp</name> + <version>x.y.z</version> + <name>SIAv2 webapp</name> <url>http://maven.apache.org</url> <properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> - <!-- FIXME needs JAVA_HOME=/usr/java/jdk-17.0.4.1 (java17 manually installed and aletrnatives activated) --> <maven.compiler.source>7</maven.compiler.source> <maven.compiler.target>7</maven.compiler.target> </properties> @@ -38,6 +37,7 @@ <artifactId>jackson-databind</artifactId> <version>2.15.1</version> </dependency> + <!-- https://mvnrepository.com/artifact/com.fasterxml.jackson.core/jackson-core --> <dependency> <groupId>com.fasterxml.jackson.core</groupId> @@ -89,13 +89,6 @@ <scope>provided</scope> </dependency> - <dependency> - <groupId>com.opencsv</groupId> - <artifactId>opencsv</artifactId> - <version>5.7.1</version> - <scope>provided</scope> - </dependency> - <!-- vlkb-volib dependencies --> <!-- https://mvnrepository.com/artifact/com.googlecode.json-simple/json-simple --> @@ -114,6 +107,8 @@ </dependencies> + + <build> <finalName>${project.artifactId}-${git.buildnumber}</finalName> <plugins> diff --git a/data-discovery/src/test/java/csv-parse/CsvParser.java b/data-discovery/src/test/java/csv-parse/CsvParser.java deleted file mode 100644 index 29ce59977a46f11b99dca3aeaf32c00bf59d52e2..0000000000000000000000000000000000000000 --- a/data-discovery/src/test/java/csv-parse/CsvParser.java +++ /dev/null @@ -1,52 +0,0 @@ - -import com.opencsv.*; -import java.nio.file.Files; -import java.nio.file.Paths; -import java.nio.file.Path; -import java.util.List; -import java.util.ArrayList; -import java.io.Reader; - -class CsvParser -{ - public static void main(String[] args) throws Exception - { - Path filePath = Paths.get(args[0]); - - CsvParser parser = new CsvParser(); - - List<String[]> lines = parser.readLineByLine(filePath); - - for(String[] strArr : lines) - { - for(String str : strArr) System.out.print(str + " | "); - System.out.println(); - } - } - - public List<String[]> readLineByLine(Path filePath) throws Exception - { - CSVParser parser = new CSVParserBuilder() - .withSeparator(',') - .withIgnoreQuotations(true) - .build(); - - List<String[]> list = new ArrayList<>(); - try (Reader reader = Files.newBufferedReader(filePath)) - { - try (CSVReader csvReader = new CSVReaderBuilder(reader) - .withSkipLines(0) - .withCSVParser(parser) - .build(); - // CSVReader csvReader = new CSVReader(reader) - ) - { - String[] line; - while ((line = csvReader.readNext()) != null) { - list.add(line); - } - } - } - return list; - } -} diff --git a/data-discovery/src/test/java/csv-parse/Makefile b/data-discovery/src/test/java/csv-parse/Makefile deleted file mode 100644 index 1aa9b4eab943faa9e655a36f628e83d272428d03..0000000000000000000000000000000000000000 --- a/data-discovery/src/test/java/csv-parse/Makefile +++ /dev/null @@ -1,8 +0,0 @@ - - -build: - javac -classpath /home/robi/.m2/repository/com/opencsv/opencsv/5.7.1/opencsv-5.7.1.jar CsvParser.java - - -run: - java -classpath /home/robi/.m2/repository/com/opencsv/opencsv/5.7.1/opencsv-5.7.1.jar:.:/home/robi/.m2/repository/org/apache/commons/commons-lang3/3.4/commons-lang3-3.4.jar CsvParser /srv/vlkb/surveys/survey_populate.csv diff --git a/data-discovery/src/test/java/csv-parse/pom.xml b/data-discovery/src/test/java/csv-parse/pom.xml deleted file mode 100644 index 48357913fd16b12d91f96dbb6de8766b2322d3ae..0000000000000000000000000000000000000000 --- a/data-discovery/src/test/java/csv-parse/pom.xml +++ /dev/null @@ -1,59 +0,0 @@ -<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> - <modelVersion>4.0.0</modelVersion> - <groupId>vlkb</groupId> - <artifactId>csv-parser</artifactId> - <packaging>jar</packaging> - <version>1.0-SNAPSHOT</version> - <name>csv matadata parser</name> - <url>http://maven.apache.org</url> - - <properties> - <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> - <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> - <!-- FIXME needs JAVA_HOME=/usr/java/jdk-17.0.4.1 (java17 manually installed and aletrnatives activated) --> - <maven.compiler.source>17</maven.compiler.source> - <maven.compiler.target>17</maven.compiler.target> - </properties> - - - <dependencies> - - <dependency> - <groupId>com.opencsv</groupId> - <artifactId>opencsv</artifactId> - <version>5.7.1</version> - <scope>provided</scope> - </dependency> - - - <dependency> - <groupId>junit</groupId> - <artifactId>junit</artifactId> - <version>3.8.1</version> - <scope>test</scope> - </dependency> - - </dependencies> - - <build> - <finalName>csv-parser</finalName> - <plugins> - <plugin> - <!-- Build an executable JAR --> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-jar-plugin</artifactId> - <version>3.1.0</version> - <configuration> - <archive> - <manifest> - <addClasspath>true</addClasspath> - <classpathPrefix>lib/</classpathPrefix> - <mainClass>CsvParser</mainClass> - </manifest> - </archive> - </configuration> - </plugin> - </plugins> </build> - -</project>