An example of using Future API which availabe upon 1.5 JVM

http://www.alittlemadness.com/?p=32

The other example, make a method timeout and interrupt for sure

http://mrfeinberg.com/blog/archives/000016.html