From bd91de4a839fd4726064bec924781757172f612a Mon Sep 17 00:00:00 2001 From: Yossi Itigin Date: Sun, 9 Apr 2023 15:56:04 +0300 Subject: [PATCH] JAVA/TEST: Wait for active message to arrive before checking data --- .../java/src/test/java/org/openucx/jucx/UcpEndpointTest.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bindings/java/src/test/java/org/openucx/jucx/UcpEndpointTest.java b/bindings/java/src/test/java/org/openucx/jucx/UcpEndpointTest.java index 4fa5e1c315d..6768ab3884d 100644 --- a/bindings/java/src/test/java/org/openucx/jucx/UcpEndpointTest.java +++ b/bindings/java/src/test/java/org/openucx/jucx/UcpEndpointTest.java @@ -735,7 +735,8 @@ public void onSuccess(UcpRequest request) { sendData.getMemory().getAddress(), 2L, UcpConstants.UCP_AM_FLAG_PERSISTENT_DATA, null, new UcpRequestParams().setMemoryType(memType).setMemoryHandle(sendData.getMemory())); - while (!Arrays.stream(requests).allMatch(r -> (r != null) && r.isCompleted())) { + while (!Arrays.stream(requests).allMatch(r -> (r != null) && r.isCompleted()) || + (persistantAmData.get() == null)) { worker1.progress(); worker2.progress(); }