Skip to content

Commit 517f102

Browse files
authored
Add tests for database structure (#170)
* Update Gradle * Update dependencies * Fix config * Add tests for database structure #1 * Add tests for database structure #2
1 parent fbe42c0 commit 517f102

File tree

21 files changed

+151
-34
lines changed

21 files changed

+151
-34
lines changed

build.gradle.kts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ description = "Experiments with Java"
99

1010
allprojects {
1111
group = "io.github.mfvanek"
12-
version = "0.2.0"
12+
version = "0.2.1"
1313

1414
repositories {
1515
mavenLocal()
@@ -19,7 +19,7 @@ allprojects {
1919

2020
tasks {
2121
wrapper {
22-
gradleVersion = "8.7"
22+
gradleVersion = "8.10.2"
2323
}
2424
}
2525

buildSrc/src/main/kotlin/sb-ot-demo.java-conventions.gradle.kts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ dependencies {
2020

2121
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine")
2222

23-
errorprone("com.google.errorprone:error_prone_core:2.26.1")
24-
errorprone("jp.skypencil.errorprone.slf4j:errorprone-slf4j:0.1.23")
23+
errorprone("com.google.errorprone:error_prone_core:2.33.0")
24+
errorprone("jp.skypencil.errorprone.slf4j:errorprone-slf4j:0.1.28")
2525
}
2626

2727
java {

common-internal-bom/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ dependencies {
1212
api(platform("org.assertj:assertj-bom:3.26.3"))
1313
api(platform("org.testcontainers:testcontainers-bom:1.20.2"))
1414
api(platform("org.junit:junit-bom:5.11.2"))
15-
api(platform("io.github.mfvanek:pg-index-health-bom:0.13.0"))
15+
api(platform("io.github.mfvanek:pg-index-health-bom:0.13.1"))
1616

1717
constraints {
1818
api("org.liquibase:liquibase-core:4.29.2")

docker/docker-compose-base.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ services:
2222
- jaeger-example
2323

2424
zookeeper1:
25-
image: confluentinc/cp-zookeeper:7.5.3
25+
image: confluentinc/cp-zookeeper:7.7.1
2626
hostname: zookeeper1
2727
container_name: zookeeper1
2828
ports:
@@ -35,7 +35,7 @@ services:
3535
- jaeger-example
3636

3737
kafka1:
38-
image: confluentinc/cp-kafka:7.5.3
38+
image: confluentinc/cp-kafka:7.7.1
3939
hostname: kafka1
4040
container_name: kafka1
4141
ports:
@@ -86,7 +86,7 @@ services:
8686

8787
postgres:
8888
container_name: postgres
89-
image: postgres:16.2
89+
image: postgres:16.4
9090
shm_size: "2gb"
9191
environment:
9292
POSTGRES_DB: "otel_demo_db"

gradle/wrapper/gradle-wrapper.jar

130 Bytes
Binary file not shown.

gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-bin.zip
3+
distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-bin.zip
44
networkTimeout=10000
55
validateDistributionUrl=true
66
zipStoreBase=GRADLE_USER_HOME

gradlew

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@
1515
# See the License for the specific language governing permissions and
1616
# limitations under the License.
1717
#
18+
# SPDX-License-Identifier: Apache-2.0
19+
#
1820

1921
##############################################################################
2022
#
@@ -55,7 +57,7 @@
5557
# Darwin, MinGW, and NonStop.
5658
#
5759
# (3) This script is generated from the Groovy template
58-
# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
60+
# https://github.com/gradle/gradle/blob/HEAD/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
5961
# within the Gradle project.
6062
#
6163
# You can find Gradle at https://github.com/gradle/gradle/.
@@ -84,7 +86,8 @@ done
8486
# shellcheck disable=SC2034
8587
APP_BASE_NAME=${0##*/}
8688
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
87-
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit
89+
APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s
90+
' "$PWD" ) || exit
8891

8992
# Use the maximum available, or set MAX_FD != -1 to use that value.
9093
MAX_FD=maximum

gradlew.bat

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@
1313
@rem See the License for the specific language governing permissions and
1414
@rem limitations under the License.
1515
@rem
16+
@rem SPDX-License-Identifier: Apache-2.0
17+
@rem
1618

1719
@if "%DEBUG%"=="" @echo off
1820
@rem ##########################################################################

spring-boot-2-demo-app/build.gradle.kts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@ plugins {
77

88
dependencies {
99
implementation(platform(project(":common-internal-bom")))
10-
implementation(platform("org.springdoc:springdoc-openapi:1.7.0"))
10+
implementation(platform("org.springdoc:springdoc-openapi:1.7.0")) {
11+
because("version 1.8.0 brings incompatible logging library")
12+
}
1113
implementation(platform("org.springframework.boot:spring-boot-dependencies:2.7.18"))
1214
implementation(platform("org.springframework.cloud:spring-cloud-dependencies:2021.0.9"))
1315
implementation(platform("org.springframework.cloud:spring-cloud-sleuth-otel-dependencies:1.1.4"))
@@ -40,6 +42,7 @@ dependencies {
4042
testImplementation("org.testcontainers:kafka")
4143
testImplementation("org.springframework.kafka:spring-kafka-test")
4244
testImplementation("org.awaitility:awaitility")
45+
testImplementation("io.github.mfvanek:pg-index-health-test-starter")
4346
}
4447

4548
springBoot {

spring-boot-2-demo-app/src/main/resources/application.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,8 +63,9 @@ spring:
6363
enable-logging: true
6464
log-level: INFO
6565
includes: QUERY
66-
template:
67-
query-timeout: 1 # 1 second
66+
jdbc:
67+
template:
68+
query-timeout: 1s
6869

6970
management:
7071
server:

0 commit comments

Comments
 (0)