[JAVA-13966] Upgraded h2 database to 2.1.214 + clean up (#12711)

* [JAVA-13966] Upgraded h2 database to 2.1.214

* [JAVA-13966] fixed tests for libraries-apache-commons

* [JAVA-13966] fixed tests

* [JAVA-13966] fixed tests

* [JAVA-13966] fixed tests JAVA-JPA MODULE

* [JAVA-13966] Made ninja submodule part of web-modules(parent)

* [JAVA-13966] Fixed naming convention for pmd

* [JAVA-13966] Moved tests of ninja-module to ManualTest category

* [JAVA-13966] Fix tests

Co-authored-by: panagiotiskakos <panagiotis.kakos@libra-is.com>
This commit is contained in:
panos-kakos 2022-10-19 19:47:05 +01:00 committed by GitHub
parent c627d0c53f
commit eb17d0e2ed
23 changed files with 34 additions and 37 deletions

View File

@ -46,8 +46,4 @@
</plugins> </plugins>
</build> </build>
<properties>
<h2.version>1.4.191</h2.version>
</properties>
</project> </project>

View File

@ -64,7 +64,6 @@
<properties> <properties>
<spring.version>5.0.9.RELEASE</spring.version> <spring.version>5.0.9.RELEASE</spring.version>
<h2.version>1.4.199</h2.version>
<apacheds.version>2.0.0.AM26</apacheds.version> <apacheds.version>2.0.0.AM26</apacheds.version>
<source.version>1.8</source.version> <source.version>1.8</source.version>
<target.version>1.8</target.version> <target.version>1.8</target.version>

View File

@ -21,17 +21,17 @@ CREATE TABLE employee_legacy(
); );
INSERT INTO employee (firstname,lastname,salary,hireddate) VALUES ('John', 'Doe', 10000.10, to_date('01-01-2001','dd-mm-yyyy')); INSERT INTO employee (firstname,lastname,salary,hireddate) VALUES ('John', 'Doe', 10000.10, PARSEDATETIME('20010101','yyyyMMdd'));
INSERT INTO employee (firstname,lastname,salary,hireddate) VALUES ('Kevin', 'Smith', 20000.20, to_date('02-02-2002','dd-mm-yyyy')); INSERT INTO employee (firstname,lastname,salary,hireddate) VALUES ('Kevin', 'Smith', 20000.20, PARSEDATETIME('20020202','yyyyMMdd'));
INSERT INTO employee (firstname,lastname,salary,hireddate) VALUES ('Kim', 'Smith', 30000.30, to_date('03-03-2003','dd-mm-yyyy')); INSERT INTO employee (firstname,lastname,salary,hireddate) VALUES ('Kim', 'Smith', 30000.30, PARSEDATETIME('20030303','yyyyMMdd'));
INSERT INTO employee (firstname,lastname,salary,hireddate) VALUES ('Stephen', 'Torvalds', 40000.40, to_date('04-04-2004','dd-mm-yyyy')); INSERT INTO employee (firstname,lastname,salary,hireddate) VALUES ('Stephen', 'Torvalds', 40000.40, PARSEDATETIME('20040404','yyyyMMdd'));
INSERT INTO employee (firstname,lastname,salary,hireddate) VALUES ('Christian', 'Reynolds', 50000.50, to_date('05-05-2005','dd-mm-yyyy')); INSERT INTO employee (firstname,lastname,salary,hireddate) VALUES ('Christian', 'Reynolds', 50000.50, PARSEDATETIME('20050505','yyyyMMdd'));
INSERT INTO employee_legacy (first_name,last_name,salary,hired_date) VALUES ('John', 'Doe', 10000.10, to_date('01-01-2001','dd-mm-yyyy')); INSERT INTO employee_legacy (first_name,last_name,salary,hired_date) VALUES ('John', 'Doe', 10000.10, PARSEDATETIME('20010101','yyyyMMdd'));
INSERT INTO employee_legacy (first_name,last_name,salary,hired_date) VALUES ('Kevin', 'Smith', 20000.20, to_date('02-02-2002','dd-mm-yyyy')); INSERT INTO employee_legacy (first_name,last_name,salary,hired_date) VALUES ('Kevin', 'Smith', 20000.20, PARSEDATETIME('20020202','yyyyMMdd'));
INSERT INTO employee_legacy (first_name,last_name,salary,hired_date) VALUES ('Kim', 'Smith', 30000.30, to_date('03-03-2003','dd-mm-yyyy')); INSERT INTO employee_legacy (first_name,last_name,salary,hired_date) VALUES ('Kim', 'Smith', 30000.30, PARSEDATETIME('20030303','yyyyMMdd'));
INSERT INTO employee_legacy (first_name,last_name,salary,hired_date) VALUES ('Stephen', 'Torvalds', 40000.40, to_date('04-04-2004','dd-mm-yyyy')); INSERT INTO employee_legacy (first_name,last_name,salary,hired_date) VALUES ('Stephen', 'Torvalds', 40000.40, PARSEDATETIME('20040404','yyyyMMdd'));
INSERT INTO employee_legacy (first_name,last_name,salary,hired_date) VALUES ('Christian', 'Reynolds', 50000.50, to_date('05-05-2005','dd-mm-yyyy')); INSERT INTO employee_legacy (first_name,last_name,salary,hired_date) VALUES ('Christian', 'Reynolds', 50000.50, PARSEDATETIME('20050505','yyyyMMdd'));
INSERT INTO email (employeeid,address) VALUES (1, 'john@baeldung.com'); INSERT INTO email (employeeid,address) VALUES (1, 'john@baeldung.com');
INSERT INTO email (employeeid,address) VALUES (1, 'john@gmail.com'); INSERT INTO email (employeeid,address) VALUES (1, 'john@gmail.com');

View File

@ -189,6 +189,7 @@
<dbunit.version>2.7.0</dbunit.version> <dbunit.version>2.7.0</dbunit.version>
<archunit.version>0.14.1</archunit.version> <archunit.version>0.14.1</archunit.version>
<modelassert.version>1.0.0</modelassert.version> <modelassert.version>1.0.0</modelassert.version>
<h2.version>1.4.200</h2.version>
</properties> </properties>
</project> </project>

View File

@ -1,28 +1,25 @@
CREATE TABLE IF NOT EXISTS CLIENTS CREATE TABLE IF NOT EXISTS CLIENTS
( (
`id` int AUTO_INCREMENT NOT NULL, `id` int PRIMARY KEY AUTO_INCREMENT NOT NULL,
`first_name` varchar(100) NOT NULL, `first_name` varchar(100) NOT NULL,
`last_name` varchar(100) NOT NULL, `last_name` varchar(100) NOT NULL
PRIMARY KEY (`id`)
); );
CREATE TABLE IF NOT EXISTS ITEMS CREATE TABLE IF NOT EXISTS ITEMS
( (
`id` int AUTO_INCREMENT NOT NULL, `id` int PRIMARY KEY AUTO_INCREMENT NOT NULL,
`title` varchar(100) NOT NULL, `title` varchar(100) NOT NULL,
`produced` date, `produced` date,
`price` float, `price` float
PRIMARY KEY (`id`)
); );
CREATE TABLE IF NOT EXISTS PURCHASES CREATE TABLE IF NOT EXISTS PURCHASES
( (
`id` int NOT NULL AUTO_INCREMENT, `id` int PRIMARY KEY AUTO_INCREMENT NOT NULL,
`id_user` int NOT NULL, `id_user` int NOT NULL,
`id_item` int NOT NULL, `id_item` int NOT NULL,
`total_price` float NOT NULL, `total_price` float NOT NULL,
`quantity` int(11) NOT NULL, `quantity` int NOT NULL,
PRIMARY KEY (`id`),
FOREIGN KEY (`id_user`) REFERENCES CLIENTS (`id`) ON DELETE CASCADE, FOREIGN KEY (`id_user`) REFERENCES CLIENTS (`id`) ON DELETE CASCADE,
FOREIGN KEY (`id_item`) REFERENCES ITEMS (`id`) ON DELETE CASCADE ON UPDATE CASCADE FOREIGN KEY (`id_item`) REFERENCES ITEMS (`id`) ON DELETE CASCADE ON UPDATE CASCADE
); );

View File

@ -76,6 +76,7 @@
<jooq.version>3.11.11</jooq.version> <jooq.version>3.11.11</jooq.version>
<json.version>20220320</json.version> <json.version>20220320</json.version>
<microstream.storage.version>07.00.00-MS-GA</microstream.storage.version> <microstream.storage.version>07.00.00-MS-GA</microstream.storage.version>
<h2.version>1.4.200</h2.version>
</properties> </properties>
</project> </project>

View File

@ -290,6 +290,7 @@
<war.plugin.version>2.6</war.plugin.version> <war.plugin.version>2.6</war.plugin.version>
<apt-maven-plugin.version>1.1.3</apt-maven-plugin.version> <apt-maven-plugin.version>1.1.3</apt-maven-plugin.version>
<jandex.version>1.2.4.Final</jandex.version> <jandex.version>1.2.4.Final</jandex.version>
<h2.version>1.4.200</h2.version>
</properties> </properties>
</project> </project>

View File

@ -64,7 +64,6 @@
<properties> <properties>
<flyway-maven-plugin.version>8.5.13</flyway-maven-plugin.version> <flyway-maven-plugin.version>8.5.13</flyway-maven-plugin.version>
<h2.version>2.1.214</h2.version>
</properties> </properties>
</project> </project>

View File

@ -84,7 +84,6 @@
<org.springframework.data.version>1.10.6.RELEASE</org.springframework.data.version> <org.springframework.data.version>1.10.6.RELEASE</org.springframework.data.version>
<hibernate-core.version>5.6.7.Final</hibernate-core.version> <hibernate-core.version>5.6.7.Final</hibernate-core.version>
<maven.deploy.skip>true</maven.deploy.skip> <maven.deploy.skip>true</maven.deploy.skip>
<h2.version>2.1.212</h2.version>
<tomcat-dbcp.version>9.0.0.M26</tomcat-dbcp.version> <tomcat-dbcp.version>9.0.0.M26</tomcat-dbcp.version>
</properties> </properties>

View File

@ -87,6 +87,7 @@
<tomcat-dbcp.version>9.0.0.M26</tomcat-dbcp.version> <tomcat-dbcp.version>9.0.0.M26</tomcat-dbcp.version>
<mysql.version>6.0.6</mysql.version> <mysql.version>6.0.6</mysql.version>
<mariaDB4j.version>2.2.3</mariaDB4j.version> <mariaDB4j.version>2.2.3</mariaDB4j.version>
<h2.version>1.4.200</h2.version>
</properties> </properties>
</project> </project>

View File

@ -60,6 +60,7 @@
<hibernate.version>5.4.12.Final</hibernate.version> <hibernate.version>5.4.12.Final</hibernate.version>
<mysql.version>6.0.6</mysql.version> <mysql.version>6.0.6</mysql.version>
<mariaDB4j.version>2.2.3</mariaDB4j.version> <mariaDB4j.version>2.2.3</mariaDB4j.version>
<h2.version>1.4.200</h2.version>
</properties> </properties>
</project> </project>

View File

@ -137,6 +137,7 @@
<maven-processor-plugin.version>3.3.3</maven-processor-plugin.version> <maven-processor-plugin.version>3.3.3</maven-processor-plugin.version>
<build-helper-maven-plugin.version>3.0.0</build-helper-maven-plugin.version> <build-helper-maven-plugin.version>3.0.0</build-helper-maven-plugin.version>
<querydsl.version>4.3.1</querydsl.version> <querydsl.version>4.3.1</querydsl.version>
<h2.version>1.4.200</h2.version>
</properties> </properties>
</project> </project>

View File

@ -91,6 +91,7 @@
<maven-compiler-plugin.version>3.5.1</maven-compiler-plugin.version> <maven-compiler-plugin.version>3.5.1</maven-compiler-plugin.version>
<maven-processor-plugin.version>3.3.3</maven-processor-plugin.version> <maven-processor-plugin.version>3.3.3</maven-processor-plugin.version>
<build-helper-maven-plugin.version>3.0.0</build-helper-maven-plugin.version> <build-helper-maven-plugin.version>3.0.0</build-helper-maven-plugin.version>
<h2.version>1.4.200</h2.version>
</properties> </properties>
</project> </project>

View File

@ -37,7 +37,7 @@
<property name="javax.persistence.jdbc.driver" <property name="javax.persistence.jdbc.driver"
value="org.h2.Driver" /> value="org.h2.Driver" />
<property name="javax.persistence.jdbc.url" <property name="javax.persistence.jdbc.url"
value="jdbc:h2:mem:test" /> value="jdbc:h2:mem:test;MODE=LEGACY" />
<property name="javax.persistence.jdbc.user" value="sa" /> <property name="javax.persistence.jdbc.user" value="sa" />
<property name="javax.persistence.jdbc.password" value="" /> <property name="javax.persistence.jdbc.password" value="" />
<property name="hibernate.dialect" <property name="hibernate.dialect"

View File

@ -73,7 +73,6 @@
<spring-boot.version>2.6.1</spring-boot.version> <spring-boot.version>2.6.1</spring-boot.version>
<spring-test.version>5.3.13</spring-test.version> <spring-test.version>5.3.13</spring-test.version>
<junit-jupiter.version>5.8.2</junit-jupiter.version> <junit-jupiter.version>5.8.2</junit-jupiter.version>
<h2.version>1.4.200</h2.version>
</properties> </properties>
</project> </project>

View File

@ -199,7 +199,7 @@
<lifecycle-mapping.version>1.0.0</lifecycle-mapping.version> <lifecycle-mapping.version>1.0.0</lifecycle-mapping.version>
<sql-maven-plugin.version>1.5</sql-maven-plugin.version> <sql-maven-plugin.version>1.5</sql-maven-plugin.version>
<properties-maven-plugin.version>1.0.0</properties-maven-plugin.version> <properties-maven-plugin.version>1.0.0</properties-maven-plugin.version>
<h2.version>1.4.198</h2.version> <h2.version>1.4.200</h2.version>
</properties> </properties>
</project> </project>

View File

@ -83,7 +83,6 @@
<spring-mybatis.version>2.0.6</spring-mybatis.version> <spring-mybatis.version>2.0.6</spring-mybatis.version>
<mybatis.version>3.5.2</mybatis.version> <mybatis.version>3.5.2</mybatis.version>
<mybatis-spring-boot-starter.version>2.2.0</mybatis-spring-boot-starter.version> <mybatis-spring-boot-starter.version>2.2.0</mybatis-spring-boot-starter.version>
<h2.version>1.4.197</h2.version>
</properties> </properties>
</project> </project>

View File

@ -1348,7 +1348,7 @@
<maven-jxr-plugin.version>3.0.0</maven-jxr-plugin.version> <maven-jxr-plugin.version>3.0.0</maven-jxr-plugin.version>
<maven-pmd-plugin.version>3.19.0</maven-pmd-plugin.version> <maven-pmd-plugin.version>3.19.0</maven-pmd-plugin.version>
<lombok.version>1.18.24</lombok.version> <lombok.version>1.18.24</lombok.version>
<h2.version>1.4.200</h2.version> <h2.version>2.1.214</h2.version>
<guava.version>31.1-jre</guava.version> <guava.version>31.1-jre</guava.version>
<maven-jar-plugin.version>3.2.2</maven-jar-plugin.version> <maven-jar-plugin.version>3.2.2</maven-jar-plugin.version>
</properties> </properties>

View File

@ -66,7 +66,6 @@
</build> </build>
<properties> <properties>
<h2.version>1.4.199</h2.version>
<httpPort>9080</httpPort> <httpPort>9080</httpPort>
<httpsPort>9443</httpsPort> <httpsPort>9443</httpsPort>
<nimbus-jose-jwt.version>7.3</nimbus-jose-jwt.version> <nimbus-jose-jwt.version>7.3</nimbus-jose-jwt.version>

View File

@ -119,7 +119,6 @@
<javax-mail.version>1.4.7</javax-mail.version> <javax-mail.version>1.4.7</javax-mail.version>
<javax-activation.version>1.1.1</javax-activation.version> <javax-activation.version>1.1.1</javax-activation.version>
<maven-eclipse-plugin.version>2.10</maven-eclipse-plugin.version> <maven-eclipse-plugin.version>2.10</maven-eclipse-plugin.version>
<h2.version>1.4.197</h2.version>
</properties> </properties>
</project> </project>

View File

@ -3,12 +3,17 @@
xmlns="http://maven.apache.org/POM/4.0.0" xmlns="http://maven.apache.org/POM/4.0.0"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<groupId>com.baeldung</groupId>
<artifactId>ninja</artifactId> <artifactId>ninja</artifactId>
<version>1.0.0</version> <version>1.0.0</version>
<packaging>jar</packaging> <packaging>jar</packaging>
<url>http://www.ninjaframework.org</url> <url>http://www.ninjaframework.org</url>
<parent>
<groupId>com.baeldung</groupId>
<artifactId>web-modules</artifactId>
<version>1.0.0-SNAPSHOT</version>
</parent>
<dependencies> <dependencies>
<dependency> <dependency>
<groupId>org.webjars</groupId> <groupId>org.webjars</groupId>
@ -200,7 +205,6 @@
<jetty.version>9.4.18.v20190429</jetty.version> <jetty.version>9.4.18.v20190429</jetty.version>
<bootstrap.version>3.3.4</bootstrap.version> <bootstrap.version>3.3.4</bootstrap.version>
<jquery.version>2.1.3</jquery.version> <jquery.version>2.1.3</jquery.version>
<h2.version>1.4.186</h2.version>
<compiler.plugin.version>3.2</compiler.plugin.version> <compiler.plugin.version>3.2</compiler.plugin.version>
<source.version>1.8</source.version> <source.version>1.8</source.version>
<target.version>1.8</target.version> <target.version>1.8</target.version>

View File

@ -7,7 +7,7 @@ import org.doctester.testbrowser.Response;
import org.junit.Test; import org.junit.Test;
import ninja.NinjaDocTester; import ninja.NinjaDocTester;
public class ApiControllerDocTesterTest extends NinjaDocTester { public class ApiControllerDocTesterManualTest extends NinjaDocTester {
String URL_INDEX = "/"; String URL_INDEX = "/";
String URL_HELLO = "/hello"; String URL_HELLO = "/hello";

View File

@ -10,7 +10,7 @@ import ninja.Result;
import services.UserService; import services.UserService;
@RunWith(NinjaRunner.class) @RunWith(NinjaRunner.class)
public class ApiControllerMockUnitTest { public class ApiControllerMockManualTest {
@Inject private UserService userService; @Inject private UserService userService;