diff --git a/docker-compose.yml b/docker-compose.yml index 9b537999720af2ab89874bfa0ab8c9a6ef1604c7..dd2b86173c43123f9ad46d7b3c1d83597d8460f7 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -99,6 +99,8 @@ services: depends_on: fda-discovery-service: condition: service_healthy + fda-authentication-service: + condition: service_healthy fda-broker-service: condition: service_healthy fda-metadata-db: @@ -127,6 +129,8 @@ services: depends_on: fda-discovery-service: condition: service_healthy + fda-authentication-service: + condition: service_healthy fda-metadata-db: condition: service_healthy logging: @@ -178,6 +182,8 @@ services: condition: service_healthy fda-container-service: condition: service_healthy + fda-authentication-service: + condition: service_healthy fda-table-service: condition: service_healthy fda-metadata-db: @@ -209,6 +215,8 @@ services: condition: service_healthy fda-discovery-service: condition: service_healthy + fda-authentication-service: + condition: service_healthy fda-broker-service: condition: service_healthy fda-database-service: @@ -235,6 +243,8 @@ services: depends_on: fda-metadata-db: condition: service_healthy + fda-authentication-service: + condition: service_healthy fda-discovery-service: condition: service_healthy fda-query-service: diff --git a/fda-query-service/.gitignore b/fda-query-service/.gitignore index 2365e522b6b8cfd3a10e3972137e8ff081c7be47..dfa259bb44036a9421fe94d8383fe86ca3991eb4 100644 --- a/fda-query-service/.gitignore +++ b/fda-query-service/.gitignore @@ -4,6 +4,12 @@ target/ !**/src/main/**/target/ !**/src/test/**/target/ +# Documentation +docs/*.html +docs/css/ +docs/images/ + +# Docker ready ### STS ### diff --git a/fda-query-service/Dockerfile b/fda-query-service/Dockerfile index fdc80a241b32d17852e80934fdb0bce199fdf0cb..e16e7700bf37bb9f39c19e17a192bcf800da755b 100644 --- a/fda-query-service/Dockerfile +++ b/fda-query-service/Dockerfile @@ -15,6 +15,7 @@ COPY ./rest-service ./rest-service COPY ./services ./services COPY ./report ./report COPY ./api ./api +COPY ./docs ./docs # Make sure it compiles RUN mvn -q clean package -DskipTests > /dev/null diff --git a/fda-query-service/api/pom.xml b/fda-query-service/api/pom.xml index a4dde1c6beb48a60fcbae9fad5e2ae695b04d849..af44b40a5777401e793ae586a3a6b93ab197904d 100644 --- a/fda-query-service/api/pom.xml +++ b/fda-query-service/api/pom.xml @@ -16,6 +16,4 @@ <jacoco.version>0.8.7</jacoco.version> </properties> - <dependencies /> - </project> \ No newline at end of file diff --git a/fda-query-service/docs/pom.xml b/fda-query-service/docs/pom.xml new file mode 100644 index 0000000000000000000000000000000000000000..f9b9644aa3853fe8e02f06972de8ccb4b725fc4c --- /dev/null +++ b/fda-query-service/docs/pom.xml @@ -0,0 +1,39 @@ +<?xml version="1.0" encoding="UTF-8"?> +<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/xsd/maven-4.0.0.xsd"> + <modelVersion>4.0.0</modelVersion> + <parent> + <artifactId>fda-query-service</artifactId> + <groupId>at.tuwien</groupId> + <version>0.0.1-SNAPSHOT</version> + </parent> + + <artifactId>docs</artifactId> + <version>0.0.1-SNAPSHOT</version> + <name>fda-query-service-docs</name> + + <properties> + <jacoco.version>0.8.7</jacoco.version> + </properties> + + <build> + <plugins> + <plugin> + <groupId>com.soebes.maven.plugins</groupId> + <artifactId>doxygen-maven-plugin</artifactId> + <version>1.1.0</version> + <executions> + <execution> + <id>docs</id> + <phase>verify</phase> + <goals> + <goal>report</goal> + </goals> + </execution> + </executions> + </plugin> + </plugins> + </build> + +</project> \ No newline at end of file diff --git a/fda-query-service/pom.xml b/fda-query-service/pom.xml index f1cd8e06ea4da4831e683351d3aee223680febb2..136ed2d0e9d27ca463759e64307a135e0d3922a2 100644 --- a/fda-query-service/pom.xml +++ b/fda-query-service/pom.xml @@ -12,7 +12,24 @@ <artifactId>fda-query-service</artifactId> <version>0.0.1-SNAPSHOT</version> <name>fda-query-service</name> - <description>Demo project for Spring Boot</description> + <description> + The query service provides an interface to insert data into the tables created by the table service. It + also allows for view-only (possibly paginated and versioned) query execution to the raw data and consumes + messages in the message queue from the Broker Service. + </description> + <url>https://dbrepo.ossdip.at</url> + <developers> + <developer> + <name>Martin Weise</name> + <email>martin.weise@tuwien.ac.at</email> + <organization>TU Wien</organization> + </developer> + <developer> + <name>Moritz Staudinger</name> + <email>moritz.staudinger@tuwien.ac.at</email> + <organization>TU Wien</organization> + </developer> + </developers> <packaging>pom</packaging> <modules> @@ -20,6 +37,7 @@ <module>services</module> <module>report</module> <module>api</module> + <module>docs</module> </modules> <properties> @@ -33,6 +51,7 @@ <jacoco.version>0.8.7</jacoco.version> <opencsv.version>5.4</opencsv.version> <hibernate-c3po.version>5.6.3.Final</hibernate-c3po.version> + <maven-report.version>3.0.0</maven-report.version> </properties> <dependencies> @@ -248,6 +267,30 @@ </execution> </executions> </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-site-plugin</artifactId> + <version>3.7.1</version> + </plugin> + <plugin> + <groupId>org.apache.maven.plugins</groupId> + <artifactId>maven-project-info-reports-plugin</artifactId> + <version>3.0.0</version> +<!-- <configuration>--> +<!-- <outputDirectory>docs</outputDirectory>--> +<!-- </configuration>--> + </plugin> + <plugin> + <groupId>com.soebes.maven.plugins</groupId> + <artifactId>doxygen-maven-plugin</artifactId> + <version>1.1.0</version> + <configuration> + <haveDot>false</haveDot> + <quiet>false</quiet> + <projectName>This is a Test Project (basicReportTest)</projectName> + <outputDirectory>docs</outputDirectory> + </configuration> + </plugin> </plugins> </build> diff --git a/fda-query-service/services/pom.xml b/fda-query-service/services/pom.xml index a66749ad2fd4b6f27961ec56df9a2514059d230c..795e5ad11d4ef17748aba40eca2e228a4303cf0e 100644 --- a/fda-query-service/services/pom.xml +++ b/fda-query-service/services/pom.xml @@ -10,13 +10,14 @@ </parent> <artifactId>services</artifactId> + <version>0.0.1-SNAPSHOT</version> + <name>fda-query-service-services</name> <dependencies> <dependency> <groupId>at.tuwien</groupId> <artifactId>api</artifactId> <version>0.0.1-SNAPSHOT</version> - <scope>compile</scope> </dependency> </dependencies> diff --git a/fda-query-service/services/src/main/java/at/tuwien/service/CommaValueService.java b/fda-query-service/services/src/main/java/at/tuwien/service/CommaValueService.java index c06664088e68b162926d3d24baff765efb39e894..5aa2df433ff1edab0215fe8dd2a98787acdbdb99 100644 --- a/fda-query-service/services/src/main/java/at/tuwien/service/CommaValueService.java +++ b/fda-query-service/services/src/main/java/at/tuwien/service/CommaValueService.java @@ -2,7 +2,6 @@ package at.tuwien.service; import at.tuwien.api.database.table.TableCsvDto; import at.tuwien.exception.*; -import org.springframework.core.io.InputStreamResource; public interface CommaValueService { @@ -14,9 +13,10 @@ public interface CommaValueService { * @param tableId The table id. * @param location The location. * @return The data from the location. - * @throws TableNotFoundException Table with id not found. - * @throws DatabaseNotFoundException Database with id not found. - * @throws FileStorageException File could not be processed. + * @throws TableNotFoundException Table with id not found. + * @throws DatabaseNotFoundException Database with id not found. + * @throws FileStorageException File could not be processed. + * @throws ContainerNotFoundException The container with id is not found. */ TableCsvDto read(Long containerId, Long databaseId, Long tableId, String location) throws TableNotFoundException, DatabaseNotFoundException, FileStorageException, ContainerNotFoundException; @@ -30,13 +30,14 @@ public interface CommaValueService { * @param location The location. * @param separator Data separator. * @param skipLines Skip first n lines. - * @param nullElement The element representing {@link null}. - * @param falseElement The element representing {@link false}. - * @param trueElement The element representing {@link true}. + * @param nullElement The element representing null. + * @param falseElement The element representing false. + * @param trueElement The element representing true. * @return The data from the location. - * @throws TableNotFoundException Table with id not found. - * @throws DatabaseNotFoundException Database with id not found. - * @throws FileStorageException File could not be processed. + * @throws TableNotFoundException Table with id not found. + * @throws DatabaseNotFoundException Database with id not found. + * @throws FileStorageException File could not be processed. + * @throws ContainerNotFoundException The container with id not found. */ TableCsvDto read(Long containerId, Long databaseId, Long tableId, String location, Character separator, Long skipLines, String nullElement, String falseElement, String trueElement) throws TableNotFoundException, DatabaseNotFoundException, FileStorageException, ContainerNotFoundException;