Ejemplo de async de FutableFuture
CompletableFuture.runAsync(() -> {
try {
TimeUnit.SECONDS.sleep(3);
System.out.println("I'm special thread "+ContextHolder.getContext());
} catch (InterruptedException e) {
e.printStackTrace();
}
});
code swifter