<div dir="ltr"><div><div><div><div>Hi,<br><br></div>I&#39;m trying to perform expensive tasks (like sending email/sms etc) as an async task (using CompletableFuture API) after my undertow worker completes and i&#39;m about to respond to the client. These tasks are supposed to work like fire and forget and I don&#39;t want to wait until the task completes and then respond to the client.<br><br></div>I&#39;ve noticed that sometimes the task doesn&#39;t execute and sometimes it does. It&#39;s inconsistent and hard to reproduce. Is there a way to be able to perform these async tasks consistently? May be i&#39;m using wrong thread-pool? Or may be there&#39;s already a way in Undertow to do such tasks.<br><br></div>Please comment.<br><br></div>Thanks.<br></div>