From f79c0bf8dcee0011411afe4efc38b771b073c599 Mon Sep 17 00:00:00 2001 From: Hieu Date: Sat, 29 Jun 2024 18:04:19 +0700 Subject: [PATCH 1/6] Correct grammar a bit --- order/src/main/resources/config/application.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/order/src/main/resources/config/application.yml b/order/src/main/resources/config/application.yml index 2ab282d..e1fc3d9 100644 --- a/order/src/main/resources/config/application.yml +++ b/order/src/main/resources/config/application.yml @@ -1,6 +1,6 @@ spring: profiles: - active: local # Activate "local" profile by default + active: local # Activate profile "local" by default jackson: default-property-inclusion: non_null messages: From 0101a402a9c80a7e1d87dcb0aeab3da8bde7f782 Mon Sep 17 00:00:00 2001 From: Hieu Date: Mon, 20 May 2024 14:14:00 +0700 Subject: [PATCH 2/6] Bump the versions of spring-boot and spring-cloud to the latest --- bom/pom.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bom/pom.xml b/bom/pom.xml index b951e25..70d6d76 100644 --- a/bom/pom.xml +++ b/bom/pom.xml @@ -44,8 +44,8 @@ 17 - 3.0.0 - 2021.0.4 + 3.2.5 + 2023.0.1 1.3.3 1.1.0-M6 1.6.9 From f4fe19cd92e03120af988029bc2c87a451cde294 Mon Sep 17 00:00:00 2001 From: Hieu Date: Mon, 20 May 2024 16:50:16 +0700 Subject: [PATCH 3/6] Fix an issue of Liquibase 4.24 --- order/src/main/resources/config/application-local.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/order/src/main/resources/config/application-local.yml b/order/src/main/resources/config/application-local.yml index 4c6f2e5..bdadfb4 100644 --- a/order/src/main/resources/config/application-local.yml +++ b/order/src/main/resources/config/application-local.yml @@ -10,7 +10,10 @@ spring: # Drop the existing to repopulate the whole database drop-first: true # Used for development to update the changelogs continuously - clear-checksums: true + # clear-checksums: true + # Temporarily set it to false to resolve an issue from Liquibase 4.24 + # See https://github.com/liquibase/liquibase/issues/5610#issuecomment-2024174007 + clear-checksums: false kafka: bootstrap-servers: "localhost:9092" properties: From 208c41e9c23ebd1f1178276ec8c77b94ea7873dd Mon Sep 17 00:00:00 2001 From: Hieu Date: Mon, 20 May 2024 15:32:09 +0700 Subject: [PATCH 4/6] Replace Hibernate Types with Hypersistence Utils * See https://github.com/vladmihalcea/hypersistence-utils?tab=readme-ov-file#migrating-to-version-3 --- bom/pom.xml | 16 +++++++++------- order/pom.xml | 12 +++++++----- .../com/emeraldhieu/vinci/order/logic/Order.java | 2 +- shipping/pom.xml | 12 +++++++----- 4 files changed, 24 insertions(+), 18 deletions(-) diff --git a/bom/pom.xml b/bom/pom.xml index 70d6d76..d0e9805 100644 --- a/bom/pom.xml +++ b/bom/pom.xml @@ -69,7 +69,7 @@ 4.1.0 2.0.0 31.1-jre - 2.20.0 + 3.7.5 7.3.0 1.11.1 9.15.2 @@ -225,13 +225,15 @@ + Hibernate support for Spring 6 + For example, "io.hypersistence.utils.hibernate.type.json.JsonType" + Mind that Hibernate Types has been renamed to Hypersistence Utils. + See https://github.com/vladmihalcea/hypersistence-utils?tab=readme-ov-file#hibernate-64-and-63 + --> - com.vladmihalcea - hibernate-types-60 - ${hibernateTypeVersion} + io.hypersistence + hypersistence-utils-hibernate-63 + ${hypersistenceUtilsHibernate63Version} diff --git a/order/pom.xml b/order/pom.xml index a1b2a42..ecfea73 100644 --- a/order/pom.xml +++ b/order/pom.xml @@ -136,12 +136,14 @@ + Hibernate support for Spring 6 + For example, "io.hypersistence.utils.hibernate.type.json.JsonType" + Mind that Hibernate Types has been renamed to Hypersistence Utils. + See https://github.com/vladmihalcea/hypersistence-utils?tab=readme-ov-file#hibernate-64-and-63 + --> - com.vladmihalcea - hibernate-types-60 + io.hypersistence + hypersistence-utils-hibernate-63 diff --git a/order/src/main/java/com/emeraldhieu/vinci/order/logic/Order.java b/order/src/main/java/com/emeraldhieu/vinci/order/logic/Order.java index c4e9190..823510d 100644 --- a/order/src/main/java/com/emeraldhieu/vinci/order/logic/Order.java +++ b/order/src/main/java/com/emeraldhieu/vinci/order/logic/Order.java @@ -1,6 +1,6 @@ package com.emeraldhieu.vinci.order.logic; -import com.vladmihalcea.hibernate.type.json.JsonType; +import io.hypersistence.utils.hibernate.type.json.JsonType; import jakarta.persistence.Column; import jakarta.persistence.Entity; import jakarta.persistence.EntityListeners; diff --git a/shipping/pom.xml b/shipping/pom.xml index 9c4c13a..bbb7788 100644 --- a/shipping/pom.xml +++ b/shipping/pom.xml @@ -119,12 +119,14 @@ + Hibernate support for Spring 6 + For example, "io.hypersistence.utils.hibernate.type.json.JsonType" + Mind that Hibernate Types has been renamed to Hypersistence Utils. + See https://github.com/vladmihalcea/hypersistence-utils?tab=readme-ov-file#hibernate-64-and-63 + --> - com.vladmihalcea - hibernate-types-60 + io.hypersistence + hypersistence-utils-hibernate-63 From b314d6b6931d25772429dfb03565c154634415d1 Mon Sep 17 00:00:00 2001 From: Hieu Date: Sat, 29 Jun 2024 18:03:07 +0700 Subject: [PATCH 5/6] Fix Hibernate error of JSON type when moving to hypersistence * The error is "Unable to determine SQL type name for column 'products' of table 'order' because there is no type mapping for org.hibernate.type.SqlTypes code: 1111 (OTHER)" --- .../src/main/java/com/emeraldhieu/vinci/order/logic/Order.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/order/src/main/java/com/emeraldhieu/vinci/order/logic/Order.java b/order/src/main/java/com/emeraldhieu/vinci/order/logic/Order.java index 823510d..024b0a6 100644 --- a/order/src/main/java/com/emeraldhieu/vinci/order/logic/Order.java +++ b/order/src/main/java/com/emeraldhieu/vinci/order/logic/Order.java @@ -50,7 +50,7 @@ public class Order { private String externalId; @Type(JsonType.class) - @Column(nullable = false) + @Column(nullable = false, columnDefinition = "json") private List products; @Column(nullable = false) From e2ebdfd0e8d45198cd0605066a03893042306d3c Mon Sep 17 00:00:00 2001 From: Hieu Date: Mon, 20 May 2024 15:09:54 +0700 Subject: [PATCH 6/6] Align springdoc versions to resolve NoClassDefFound --- bom/pom.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bom/pom.xml b/bom/pom.xml index d0e9805..0b0e027 100644 --- a/bom/pom.xml +++ b/bom/pom.xml @@ -48,7 +48,7 @@ 2023.0.1 1.3.3 1.1.0-M6 - 1.6.9 + 1.8.0 3.2.0 2.22.2 2.22.2 @@ -67,7 +67,7 @@ 0.9.10 0.2.0 4.1.0 - 2.0.0 + 2.5.0 31.1-jre 3.7.5 7.3.0