This is an automated email from the ASF dual-hosted git repository.
github-merge-queue[bot] pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/seatunnel.git
The following commit(s) were added to refs/heads/dev by this push:
new 309b15effe [Test][Zeta] Await asynchronous logical checkpoint metrics
(#12453)
309b15effe is described below
commit 309b15effe99423f73b6007cbe61b97bb6af7b24
Author: Goutam Adwant <[email protected]>
AuthorDate: Sat Oct 3 15:56:09 2026 +0000
[Test][Zeta] Await asynchronous logical checkpoint metrics (#12453)
Signed-off-by: Goutam Adwant <[email protected]>
---
.../EngineStateStoreLogicalMetricExportsTest.java | 119 ++++++++++++---------
1 file changed, 68 insertions(+), 51 deletions(-)
diff --git
a/seatunnel-engine/seatunnel-engine-server/src/test/java/org/apache/seatunnel/engine/server/telemetry/metrics/exports/EngineStateStoreLogicalMetricExportsTest.java
b/seatunnel-engine/seatunnel-engine-server/src/test/java/org/apache/seatunnel/engine/server/telemetry/metrics/exports/EngineStateStoreLogicalMetricExportsTest.java
index 504dc0d1bd..925cf0aa4f 100644
---
a/seatunnel-engine/seatunnel-engine-server/src/test/java/org/apache/seatunnel/engine/server/telemetry/metrics/exports/EngineStateStoreLogicalMetricExportsTest.java
+++
b/seatunnel-engine/seatunnel-engine-server/src/test/java/org/apache/seatunnel/engine/server/telemetry/metrics/exports/EngineStateStoreLogicalMetricExportsTest.java
@@ -85,58 +85,75 @@ class EngineStateStoreLogicalMetricExportsTest {
seedFinishedJobStores();
seedConnectorJarRefCounters();
- List<MetricFamilySamples> metrics =
- new
EngineStateStoreLogicalMetricExports(instance.node).collect();
+ // Logical counters are updated asynchronously by Hazelcast entry
listeners.
+ await().atMost(10, TimeUnit.SECONDS)
+ .untilAsserted(
+ () -> {
+ List<MetricFamilySamples> metrics =
+ new
EngineStateStoreLogicalMetricExports(instance.node)
+ .collect();
- Assertions.assertEquals(
- 3d,
- findSampleValue(
- metrics,
"engine_state_store_running_job_metrics_task_contexts", null));
- Assertions.assertEquals(
- 2d,
- findSampleValue(
- metrics,
-
"engine_state_store_running_job_metrics_active_partition_keys",
- null));
- Assertions.assertEquals(
- 1d, findSampleValue(metrics,
"engine_state_store_checkpoint_monitor_jobs", null));
- Assertions.assertEquals(
- 1d,
- findSampleValue(
- metrics,
-
"engine_state_store_checkpoint_monitor_in_progress_checkpoints",
- null));
- Assertions.assertEquals(
- 2d,
- findSampleValue(
- metrics,
-
"engine_state_store_checkpoint_monitor_retained_history_entries",
- null));
- Assertions.assertEquals(
- 1d,
- findSampleValue(
- metrics,
- "engine_state_store_finished_job_records",
- Constant.IMAP_FINISHED_JOB_STATE));
- Assertions.assertEquals(
- 1d,
- findSampleValue(
- metrics,
- "engine_state_store_finished_job_records",
- Constant.IMAP_FINISHED_JOB_METRICS));
- Assertions.assertEquals(
- 1d,
- findSampleValue(
- metrics,
- "engine_state_store_finished_job_records",
- Constant.IMAP_FINISHED_JOB_VERTEX_INFO));
- Assertions.assertEquals(
- 1d,
- findSampleValue(metrics,
"engine_state_store_connector_jar_tracked_jars", null));
- Assertions.assertEquals(
- 2d,
- findSampleValue(
- metrics,
"engine_state_store_connector_jar_total_references", null));
+ Assertions.assertEquals(
+ 3d,
+ findSampleValue(
+ metrics,
+
"engine_state_store_running_job_metrics_task_contexts",
+ null));
+ Assertions.assertEquals(
+ 2d,
+ findSampleValue(
+ metrics,
+
"engine_state_store_running_job_metrics_active_partition_keys",
+ null));
+ Assertions.assertEquals(
+ 1d,
+ findSampleValue(
+ metrics,
+
"engine_state_store_checkpoint_monitor_jobs",
+ null));
+ Assertions.assertEquals(
+ 1d,
+ findSampleValue(
+ metrics,
+
"engine_state_store_checkpoint_monitor_in_progress_checkpoints",
+ null));
+ Assertions.assertEquals(
+ 2d,
+ findSampleValue(
+ metrics,
+
"engine_state_store_checkpoint_monitor_retained_history_entries",
+ null));
+ Assertions.assertEquals(
+ 1d,
+ findSampleValue(
+ metrics,
+
"engine_state_store_finished_job_records",
+ Constant.IMAP_FINISHED_JOB_STATE));
+ Assertions.assertEquals(
+ 1d,
+ findSampleValue(
+ metrics,
+
"engine_state_store_finished_job_records",
+
Constant.IMAP_FINISHED_JOB_METRICS));
+ Assertions.assertEquals(
+ 1d,
+ findSampleValue(
+ metrics,
+
"engine_state_store_finished_job_records",
+
Constant.IMAP_FINISHED_JOB_VERTEX_INFO));
+ Assertions.assertEquals(
+ 1d,
+ findSampleValue(
+ metrics,
+
"engine_state_store_connector_jar_tracked_jars",
+ null));
+ Assertions.assertEquals(
+ 2d,
+ findSampleValue(
+ metrics,
+
"engine_state_store_connector_jar_total_references",
+ null));
+ });
}
@Test