Skip to content

Commit

Permalink
Merge pull request #161 from cinovo/updatedependencies
Browse files Browse the repository at this point in the history
Update dependencies
  • Loading branch information
YukiInu authored Jul 10, 2024
2 parents b0355f6 + 6b5d682 commit dde2e5d
Show file tree
Hide file tree
Showing 49 changed files with 840 additions and 749 deletions.
37 changes: 33 additions & 4 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,37 @@
# current master
* Update dependencies
* Spring 5.3.36
* AWS 1.12.739
* Jetty 9.4.53.v20231009
* Joda-Time 2.12.7
* Log4J 2.23.1
* ActiveMQ 5.16.7
* Apache CXF 3.5.8
* JSON Small and Fast Parser 2.5.1
* Jackson 2.17.1
* Guava 33.2.1-jre
* Hazelcast 5.3.7
* Swagger 2.2.22
* Liquibase 4.28.0
* Mongo Java Driver 4.11.2
* Mongock 5.4.2
* Bouncycastle Provider 1.78.1
* Nimbus JOSE+JWT 9.40
* Commons Codec 1.17.0
* Junit 5.10.2
* Bson 2.15.1
* Concordion 4.0.1
* Removed (unused) cglib from dvalin-jaxrs
* Removed concordion-extensions
* Migrated all JUnit tests to Junit 5 syntax
* Removed mongodb-driver-legacy from mongodb
* Deprecated mongo functionality was removed
* Complete overhaul for entity handling
* The old functionality is still available with the mongodb-legacy library
* Breaking: Removed Junit 5 Vintage engine and Junit 4 (can be added in projects that need it)
* Fixed vulnerabilities: CVE-2023-52428(nimbus-jose-jwt), CVE-2024-29857,CVE-2024-30171,CVE-2024-30172,CVE-2024-34447 (bouncycastle), CVE-2024-28752 (Apache CXF)

# 1.35
* Update dependencies
* Spring 5.3.31
* AWS 1.12.641
Expand All @@ -21,10 +54,6 @@
* Migrated from JUnit 4 to JUnit 5
* Drop support for Powermock
* Switch Mockito to Mockito Inline for usage in static mocks
* Removed mongodb-driver-legacy from mongodb
* Deprecated mongo functionality was removed
* Complete overhaul for entity handling
* The old functionality is still available with the mongodb-legacy library
* Fixing an recurring ActiveMQ problem where messages can't be sent because ActiveMQ is to slow opening destination.
We do a resend after configurable retry time. If problem does not occur, nothing hanges.
* IVO generator: replaced old Apache BeanUtils with Spring beans BeanUtils
Expand Down
2 changes: 1 addition & 1 deletion archetypes/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
<modelVersion>4.0.0</modelVersion>
<packaging>pom</packaging>
<parent>
<artifactId>dvalin-parent</artifactId>
<groupId>de.taimos</groupId>
<artifactId>dvalin-parent</artifactId>
<version>1.36-SNAPSHOT</version>
</parent>
<artifactId>dvalin-archetype-parent</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion cluster/hazelcast/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<artifactId>dvalin-cluster-hazelcast</artifactId>
<name>Dvalin Hazelcast support</name>
<properties>
<hazelcast.version>5.3.6</hazelcast.version>
<hazelcast.version>5.3.7</hazelcast.version>
</properties>
<dependencies>
<dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,11 @@
import de.taimos.daemon.spring.AdditionalRunnerConfiguration;
import de.taimos.daemon.spring.RunnerConfiguration;
import de.taimos.daemon.spring.SpringDaemonExtension;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;
import org.springframework.beans.factory.annotation.Value;

import static org.junit.Assert.assertEquals;

/**
* Copyright 2023 Cinovo AG<br>
* <br>
Expand All @@ -29,8 +28,7 @@ public class AdditionalConfigTest {
*/
@Test
public void testAdditionalConfiguration() {
assertEquals("The propery 'jwtauth.issuer' was not equals to the value of AdditionalTestConfig.TEST_VALUE",
AdditionalTestConfig.TEST_VALUE, this.jwtIssuer);
Assertions.assertEquals(AdditionalTestConfig.TEST_VALUE, this.jwtIssuer, "The propery 'jwtauth.issuer' was not equals to the value of AdditionalTestConfig.TEST_VALUE");
}
}

30 changes: 15 additions & 15 deletions daemon/src/test/java/de/taimos/dvalin/daemon/SpringLockTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@
* #L%
*/

import org.junit.Assert;
import org.junit.Test;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;

public class SpringLockTest {
class SpringLockTest {

@Test
public void startContext() throws Exception {
Expand All @@ -35,8 +35,8 @@ public void startContext() throws Exception {
public void testCtx() throws Exception {
TestAdapter adapter = new TestAdapter("good");
adapter.doStart();
Assert.assertNotNull(adapter.getContext());
Assert.assertNotNull(adapter.getContext().getId());
Assertions.assertNotNull(adapter.getContext());
Assertions.assertNotNull(adapter.getContext().getId());
adapter.doStop();
}

Expand All @@ -45,29 +45,29 @@ public void testStopBad() {
TestAdapter adapter = new TestAdapter("bad");
try {
adapter.doStart();
Assert.fail();
Assertions.fail();
} catch (Exception e) {
// should happen
}
Assert.assertNull(adapter.getContext());
Assertions.assertNull(adapter.getContext());
try {
adapter.doStop();
Assert.fail();
Assertions.fail();
} catch (Exception e) {
Assert.assertEquals(RuntimeException.class, e.getClass());
Assertions.assertEquals(RuntimeException.class, e.getClass());
}
}

@Test
public void testDoubleStart() throws Exception {
TestAdapter adapter = new TestAdapter("good");
adapter.doStart();
Assert.assertNotNull(adapter.getContext());
Assertions.assertNotNull(adapter.getContext());
try {
adapter.doStart();
Assert.fail();
Assertions.fail();
} catch (Exception e) {
Assert.assertEquals(RuntimeException.class, e.getClass());
Assertions.assertEquals(RuntimeException.class, e.getClass());
}
adapter.doStop();
}
Expand All @@ -76,13 +76,13 @@ public void testDoubleStart() throws Exception {
public void testDoubleStop() throws Exception {
TestAdapter adapter = new TestAdapter("good");
adapter.doStart();
Assert.assertNotNull(adapter.getContext());
Assertions.assertNotNull(adapter.getContext());
adapter.doStop();
try {
adapter.doStop();
Assert.fail();
Assertions.fail();
} catch (Exception e) {
Assert.assertEquals(RuntimeException.class, e.getClass());
Assertions.assertEquals(RuntimeException.class, e.getClass());
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,9 @@
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
Expand All @@ -20,35 +20,35 @@
* #L%
*/

import org.junit.Assert;
import org.junit.Test;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;

public class EnumMarshallerTest {

@Test
public void marshall() throws Exception {
EnumMarshaller m = new EnumMarshaller();
Assert.assertEquals(TestEnum.EnumValue1.toString(), m.marshall(TestEnum.EnumValue1));
Assert.assertEquals(TestEnum.ENUMVALUE2.toString(), m.marshall(TestEnum.ENUMVALUE2));
Assertions.assertEquals(TestEnum.EnumValue1.toString(), m.marshall(TestEnum.EnumValue1));
Assertions.assertEquals(TestEnum.ENUMVALUE2.toString(), m.marshall(TestEnum.ENUMVALUE2));
}

@Test
public void marshallNull() throws Exception {
EnumMarshaller m = new EnumMarshaller();
Assert.assertNull(m.marshall(null));
Assertions.assertNull(m.marshall(null));
}

@Test
public void unmarshall() throws Exception {
EnumMarshaller m = new EnumMarshaller();
Assert.assertEquals(TestEnum.EnumValue1, m.unmarshall(TestEnum.class, TestEnum.EnumValue1.toString()));
Assert.assertEquals(TestEnum.ENUMVALUE2, m.unmarshall(TestEnum.class, TestEnum.ENUMVALUE2.toString()));
Assertions.assertEquals(TestEnum.EnumValue1, m.unmarshall(TestEnum.class, TestEnum.EnumValue1.toString()));
Assertions.assertEquals(TestEnum.ENUMVALUE2, m.unmarshall(TestEnum.class, TestEnum.ENUMVALUE2.toString()));
}

@Test
public void unmarshallNull() throws Exception {
EnumMarshaller m = new EnumMarshaller();
Assert.assertNull(m.unmarshall(TestEnum.class, null));
Assertions.assertNull(m.unmarshall(TestEnum.class, null));
}

}
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
import java.util.List;
import java.util.Locale;

import org.junit.Assert;
import org.junit.Before;
import org.junit.Test;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.Resource;
Expand Down Expand Up @@ -69,7 +69,7 @@ private static void doInjection(Object bean, Object dependency, Field field) {

protected abstract List<II18nResourceHandler> getResourceHandler();

@Before
@BeforeEach
public void setUp() throws NoSuchMethodException, InvocationTargetException, IllegalAccessException {
InjectionUtils.injectValue(this.resourceAccess, "DEFAULT_LOCALE_STRING", "de");
InjectionUtils.inject(this.resourceAccess, this.getResourceHandler());
Expand All @@ -82,27 +82,27 @@ public void setUp() throws NoSuchMethodException, InvocationTargetException, Ill
@Test
public void testNonExisting() {
String notExisting = this.resourceAccess.getString("notExisting");
Assert.assertEquals("!notExisting!", notExisting);
Assertions.assertEquals("!notExisting!", notExisting);
}

@Test
public void testBasicLanguageGet() {
{
//default locale
String text = this.resourceAccess.getString("textA");
Assert.assertEquals("TextAGerman", text);
Assertions.assertEquals("TextAGerman", text);
}

{
//fixed locale
String text = this.resourceAccess.getString(Locale.ENGLISH, "textA");
Assert.assertEquals("TextAEnglish", text);
Assertions.assertEquals("TextAEnglish", text);
}

{
//nonexistant locale -> default to default language
String text = this.resourceAccess.getString(Locale.ITALIAN, "textA");
Assert.assertEquals("TextAGerman", text);
Assertions.assertEquals("TextAGerman", text);
}
}

Expand All @@ -111,19 +111,19 @@ public void testGetWithReplaces() {
{
//default locale
String text = this.resourceAccess.getString("textB", "aTest1", "aTest2", "aTest3");
Assert.assertEquals("TextBGerman aTest1 aTest3", text);
Assertions.assertEquals("TextBGerman aTest1 aTest3", text);
}

{
//fixed locale
String text = this.resourceAccess.getString(Locale.ENGLISH, "textB", "aTest1", "aTest2", "aTest3");
Assert.assertEquals("TextBEnglish aTest1 aTest3", text);
Assertions.assertEquals("TextBEnglish aTest1 aTest3", text);
}

{
//nonexistant locale -> default to default language
String text = this.resourceAccess.getString(Locale.ITALIAN, "textB", "aTest1", "aTest2", "aTest3");
Assert.assertEquals("TextBGerman aTest1 aTest3", text);
Assertions.assertEquals("TextBGerman aTest1 aTest3", text);
}
}

Expand All @@ -132,19 +132,19 @@ public void testGetEnums() {
{
//default locale
String text = this.resourceAccess.getString(TestEnum.FIELD_A);
Assert.assertEquals("EnumFieldAGerman", text);
Assertions.assertEquals("EnumFieldAGerman", text);
}

{
//fixed locale
String text = this.resourceAccess.getString(Locale.ENGLISH, TestEnum.FIELD_A);
Assert.assertEquals("EnumFieldAEnglish", text);
Assertions.assertEquals("EnumFieldAEnglish", text);
}

{
//nonexistant locale -> default to default language
String text = this.resourceAccess.getString(Locale.ITALIAN, TestEnum.FIELD_B);
Assert.assertEquals("EnumFieldBGerman", text);
Assertions.assertEquals("EnumFieldBGerman", text);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

import de.taimos.dvalin.i18n.xml.I18nXMLHandler;
import de.taimos.dvalin.i18n.yaml.I18nYAMLHandler;
import org.junit.Assert;
import org.junit.Test;
import org.junit.jupiter.api.Assertions;
import org.junit.jupiter.api.Test;
import org.springframework.core.io.Resource;

import java.util.ArrayList;
Expand Down Expand Up @@ -38,13 +38,13 @@ public void testXMLandYAMLFiles() {
{
//default locale
String text = this.resourceAccess.getString("xmlOnly");
Assert.assertEquals("nur in XML", text);
Assertions.assertEquals("nur in XML", text);
}

{
//fixed locale
String text = this.resourceAccess.getString(Locale.ENGLISH, "yamlOnly");
Assert.assertEquals("only in YAML", text);
Assertions.assertEquals("only in YAML", text);
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public final class InterconnectConnectorBurstTest implements Runnable {
* @throws Exception If ...
*/
public static void main(String[] args) throws Exception {
TestHelper.initBrokerEnv("failover:tcp://localhost:61616");
de.taimos.dvalin.interconnect.core.TestHelper.initBrokerEnv("failover:tcp://localhost:61616");
try {
System.out.println("begin");
for (int i = 0; i < InterconnectConnectorBurstTest.THREADS; i++) {
Expand All @@ -54,7 +54,7 @@ public static void main(String[] args) throws Exception {
System.out.println("end");
System.out.println("duration: " + ((end - begin) / 1000L / 1000L) + " ms");
} finally {
TestHelper.closeBrokerEnv();
de.taimos.dvalin.interconnect.core.TestHelper.closeBrokerEnv();
}
}

Expand Down
Loading

0 comments on commit dde2e5d

Please sign in to comment.