Skip to content

Commit eac8c31

Browse files
committed
Attempt to fix Debezium tests
1 parent 42f4579 commit eac8c31

File tree

3 files changed

+7
-6
lines changed

3 files changed

+7
-6
lines changed

spring-integration-debezium/src/test/java/org/springframework/integration/debezium/DebeziumMySqlTestContainer.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2023-2023 the original author or authors.
2+
* Copyright 2023-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -37,7 +37,7 @@ public interface DebeziumMySqlTestContainer {
3737

3838
MySQLContainer<?> DEBEZIUM_MYSQL =
3939
new MySQLContainer<>(
40-
DockerImageName.parse("debezium/example-mysql:2.2.0.Final")
40+
DockerImageName.parse("debezium/example-mysql:2.7.0.Final")
4141
.asCompatibleSubstituteFor("mysql"))
4242
.withUsername("mysqluser")
4343
.withPassword("mysqlpw");

spring-integration-debezium/src/test/java/org/springframework/integration/debezium/it/DebeziumBatchTests.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2023-2023 the original author or authors.
2+
* Copyright 2023-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -16,6 +16,7 @@
1616

1717
package org.springframework.integration.debezium.it;
1818

19+
import java.time.Duration;
1920
import java.util.ArrayList;
2021
import java.util.List;
2122

@@ -62,7 +63,7 @@ public class DebeziumBatchTests implements DebeziumMySqlTestContainer {
6263

6364
@Test
6465
void batchMode() {
65-
await().until(this::receivePayloads, (count) -> count == EXPECTED_DB_TX_COUNT);
66+
await().atMost(Duration.ofSeconds(30)).until(this::receivePayloads, (count) -> count == EXPECTED_DB_TX_COUNT);
6667

6768
assertThat(allPayload).hasSize(EXPECTED_DB_TX_COUNT);
6869
assertThat(batchCount).isLessThan(EXPECTED_DB_TX_COUNT);

spring-integration-debezium/src/test/java/org/springframework/integration/debezium/it/DebeziumStreamTests.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2023-2023 the original author or authors.
2+
* Copyright 2023-2024 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -56,7 +56,7 @@ public class DebeziumStreamTests implements DebeziumMySqlTestContainer {
5656
void streamMode() {
5757
boolean foundDebeziumHeaders = false;
5858
for (int i = 0; i < EXPECTED_DB_TX_COUNT; i++) {
59-
Message<?> message = this.queueChannel.receive(10_000);
59+
Message<?> message = this.queueChannel.receive(30_000);
6060
assertThat(message).isNotNull();
6161

6262
if (message.getHeaders().size() > 5) {

0 commit comments

Comments
 (0)