ucx
ucx copied to clipboard
Stuck at waitForEvents
Describe the bug
The code gets stuck in a worker.waitForEvents. I do not understand how this is possible if this is non blocking. Moreover I perform worker.close(), while it is block and it still does not jump to the following line. Any idea why this happens
Steps to Reproduce
- Command line
- UCX version1.16
Setup and versions
- Ubuntu 16.4 + CPU architecture (x86_64)
Additional information (depending on the issue)
- "UCXListener" #16 prio=5 os_prio=0 tid=0x00007fb390001000 nid=0x1c850 runnable [0x00007fb3ccb78000] java.lang.Thread.State: RUNNABLE at org.openucx.jucx.ucp.UcpWorker.waitWorkerNative(Native Method) at org.openucx.jucx.ucp.UcpWorker.waitForEvents(UcpWorker.java:170) at es.bsc.comm.ucx.UCXListener.run(UCXListener.java:142) while (!this.stop) { try { try { if (worker.progress() == 0) { LOGGER.info("Waiting..."); worker.waitForEvents(); LOGGER.info("After Waiting..." } } catch (Exception e) { System.out.println("UCX: ERROR " + LOGGER.info("UCX: ERROR " + e); // worker.cancelRequest(null); } } catch (Exception e) { throw new RuntimeException(e); } LOGGER.info("RUN EVENTS " + this.stop); }
waitForEvents is calling ucp_worker_wait which is a blocking function call. can you try calling worker.signal() to make it exit?