You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The text was updated successfully, but these errors were encountered:
yenda
changed the title
Deref in task causing Interrupted Exception when ran in newVirtualThreadPerTaskExecutor
Deref in task causing a silent Interrupted Exception
Apr 17, 2024
Adding this snippet as well, deref works outside the catch:
((m/sp
(try
(m/? (m/reduce
(constantlynil)
(m/ap (let [s (m/?> (m/seed [123]))]
(m/? (m/via m/blk (throw (ex-info"BOOM" {}))))))))
(catch Exception e
(println"Catching the exception")
(try
@(future (println"Printing in future"))
(catch Exception _
(println"The deref blew up but we catch it")))
(println"This would never print without catching the exception from deref")))
@(future (println"Printing in future outside catch"))
(println"And this prints because the deref above doesn't blow up"))
(constantlynil) (constantlynil))
Even if the exception is caught and the deref is in the catch:
while:
The text was updated successfully, but these errors were encountered: