What is the task doing? If it is in a tight loop, it must check explicitly whether the interrupt flag is set and abort. If it is waiting on some resource, it will receive InterruptedException.
Regards, Praki Prakash On Wed, Jan 22, 2014 at 11:20 AM, Mark Engelberg <mark.engelb...@gmail.com>wrote: > On Wed, Jan 22, 2014 at 2:51 AM, Jozef Wagner <jozef.wag...@gmail.com>wrote: > >> You can put the computation into a future, and cancel the future after >> the timeout. >> > > I experimented with that, but it didn't seem to work. I suspect that > "canceling a future" doesn't really do what I think it should do. I would > appreciate some further clarity on how future cancellations work, and if > someone thinks it applies here, would like to see concretely how to do it. > > -- > -- > You received this message because you are subscribed to the Google > Groups "Clojure" group. > To post to this group, send email to clojure@googlegroups.com > Note that posts from new members are moderated - please be patient with > your first post. > To unsubscribe from this group, send email to > clojure+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/clojure?hl=en > --- > You received this message because you are subscribed to the Google Groups > "Clojure" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to clojure+unsubscr...@googlegroups.com. > For more options, visit https://groups.google.com/groups/opt_out. > -- -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.