UI hangs during UI.access (runnable)

Hi all,

In my application I have process that refreshes the feed for an inputed user, and updates a grid with the new items. This process (the refresh of the user’s feed) takes a time to be done (about 4-8 secs), and because of that I need to process the refresh in a publisher (it’s a reactor flux by the way) and refresh the grid with the new feed items in a callback method.
However, sometimes my UI hangs and it’s not possible to open any page in the browser. In the jstack (in the attachment) shows the UI.access thread is parked waiting for a thread to notify it, but this notify never comes.

Anyone has experienced this kind of problem using java reactor and UI.access? What could be the reason to the UI be hanged and what can be done to avoid the problem?

Code:
UI current = UI.getCurrent();
service.refreshNewEntryFeed(user)
.doOnComplete(() → current.access(() → callback.accept()))
.subscribe();

Regards,
Danilo
18418126.log (3.43 KB)