Skip to content

Commit

Permalink
chore: Clean up dhis-api and other modules using it [TECH-801] (#9302)
Browse files Browse the repository at this point in the history
* chore: Clean up dhis-api and other modules using it [TECH-801]

* chore: Enforce the ban of simple logger [TECH-801]
  • Loading branch information
enricocolasante authored Nov 25, 2021
1 parent f5a1ea7 commit 13e9f9f
Show file tree
Hide file tree
Showing 8 changed files with 104 additions and 79 deletions.
88 changes: 43 additions & 45 deletions dhis-2/dhis-api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,6 @@
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-collections4</artifactId>
Expand Down Expand Up @@ -79,24 +75,6 @@
<groupId>org.cache2k</groupId>
<artifactId>cache2k-core</artifactId>
</dependency>
<dependency>
<groupId>joda-time</groupId>
<artifactId>joda-time</artifactId>
</dependency>
<dependency>
<groupId>javax.validation</groupId>
<artifactId>validation-api</artifactId>
</dependency>
<dependency>
<groupId>org.geotools</groupId>
<artifactId>gt-opengis</artifactId>
</dependency>

<!-- SMPP -->
<dependency>
<groupId>org.jsmpp</groupId>
<artifactId>jsmpp</artifactId>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-api</artifactId>
Expand All @@ -109,22 +87,13 @@
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-slf4j-impl</artifactId>
</dependency>
<!-- Test -->

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<scope>test</scope>
<groupId>joda-time</groupId>
<artifactId>joda-time</artifactId>
</dependency>
<dependency>
<groupId>org.awaitility</groupId>
<artifactId>awaitility</artifactId>
<scope>test</scope>
<groupId>javax.validation</groupId>
<artifactId>validation-api</artifactId>
</dependency>
<dependency>
<groupId>org.hisp.dhis.rules</groupId>
Expand All @@ -150,16 +119,6 @@
<groupId>org.locationtech.jts.io</groupId>
<artifactId>jts-io-common</artifactId>
</dependency>
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-library</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>io.github.benas</groupId>
<artifactId>random-beans</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.geotools</groupId>
<artifactId>gt-geojson</artifactId>
Expand All @@ -181,6 +140,45 @@
<groupId>org.hibernate</groupId>
<artifactId>hibernate-core</artifactId>
</dependency>

<!-- SMPP -->
<dependency>
<groupId>org.jsmpp</groupId>
<artifactId>jsmpp</artifactId>
</dependency>

<!-- Test -->

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.awaitility</groupId>
<artifactId>awaitility</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-library</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>io.github.benas</groupId>
<artifactId>random-beans</artifactId>
<scope>test</scope>
</dependency>
</dependencies>

<properties>
Expand Down
13 changes: 12 additions & 1 deletion dhis-2/dhis-support/dhis-support-external/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -47,14 +47,17 @@
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-core</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
</dependency>

<!-- Other -->

<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-text</artifactId>
</dependency>

<dependency>
<groupId>com.google.api-client</groupId>
<artifactId>google-api-client</artifactId>
Expand All @@ -68,6 +71,14 @@
<artifactId>lombok</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
<groupId>javax.annotation</groupId>
<artifactId>javax.annotation-api</artifactId>
</dependency>

<!-- Test -->

Expand Down
19 changes: 16 additions & 3 deletions dhis-2/dhis-support/dhis-support-hibernate/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -48,13 +48,11 @@
<groupId>org.hibernate</groupId>
<artifactId>hibernate-ehcache</artifactId>
</dependency>

<dependency>
<groupId>com.vladmihalcea</groupId>
<artifactId>hibernate-types-52</artifactId>
<version>${hibernate-types.version}</version>
</dependency>

<dependency>
<groupId>com.mchange</groupId>
<artifactId>c3p0</artifactId>
Expand Down Expand Up @@ -115,6 +113,10 @@
<groupId>org.springframework</groupId>
<artifactId>spring-orm</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.security</groupId>
<artifactId>spring-security-core</artifactId>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
Expand Down Expand Up @@ -144,7 +146,18 @@
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
</dependency>

<dependency>
<groupId>javax.annotation</groupId>
<artifactId>javax.annotation-api</artifactId>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</dependency>
<dependency>
<groupId>org.cache2k</groupId>
<artifactId>cache2k-api</artifactId>
</dependency>
</dependencies>
<properties>
<rootDir>../../</rootDir>
Expand Down
12 changes: 4 additions & 8 deletions dhis-2/dhis-support/dhis-support-jdbc/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,22 +28,18 @@

<!-- Other -->

<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-core</artifactId>
</dependency>
<dependency>
<groupId>com.fasterxml</groupId>
<artifactId>classmate</artifactId>
</dependency>
<dependency>
<groupId>org.hibernate</groupId>
<artifactId>hibernate-spatial</artifactId>
</dependency>
<dependency>
<groupId>org.hisp</groupId>
<artifactId>quick</artifactId>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-jdbc</artifactId>
</dependency>

<!-- Test -->

Expand Down
16 changes: 16 additions & 0 deletions dhis-2/dhis-support/dhis-support-test/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,22 @@
<artifactId>gson</artifactId>
<scope>compile</scope>
</dependency>
<dependency>
<groupId>joda-time</groupId>
<artifactId>joda-time</artifactId>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-api</artifactId>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-slf4j-impl</artifactId>
</dependency>
</dependencies>
<properties>
<rootDir>../../</rootDir>
Expand Down

This file was deleted.

4 changes: 4 additions & 0 deletions dhis-2/dhis-web-api-test/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -147,6 +147,10 @@
<groupId>commons-fileupload</groupId>
<artifactId>commons-fileupload</artifactId>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-slf4j-impl</artifactId>
</dependency>

<dependency>
<groupId>org.projectlombok</groupId>
Expand Down
9 changes: 9 additions & 0 deletions dhis-2/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -688,6 +688,11 @@
</goals>
<configuration>
<rules>
<bannedDependencies>
<excludes>
<exclude>org.slf4j:slf4j-simple</exclude>
</excludes>
</bannedDependencies>
<banDuplicatePomDependencyVersions/>
<requireMavenVersion>
<version>${minimum-maven.version}</version>
Expand Down Expand Up @@ -881,6 +886,10 @@
<groupId>org.hisp.dhis.parser</groupId>
<artifactId>dhis-antlr-expression-parser</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-simple</artifactId>
</exclusion>
</exclusions>
</dependency>

Expand Down

0 comments on commit 13e9f9f

Please sign in to comment.