On a web server, several users may be accessing the same page at the same time. Java's threading model allows an application to run parallel strands servicing several requirements at the same time, though great care must be taken to ensure that the strands don't conflict.

Doing several things at the same time - Java threadsIf you have a program that you want to do several tasks at the same time, you can use threads (in Java). You create a runnable object through a constructor, start it when you want it to start and stop it when you want it to stop. And it runs in parallel with (in reality time shared with) other threads ...

Dripping taps, Java threads and the single thread modelHave you ever lain awake at night and listened to dripping taps. "drip, drip, drip" ... until you eventually fall asleep? With one tap, it's rhythmic, but with two taps the two rhythms get intertwined, and result in an apparently patternless racket. If only one tap would wait for the other, it would ...

We have a technical library of over 700 books on the subjects on which we teach.
These books are available for reference at our training centre. Also
available is the Opentalk
Forum for discussion of technical questions.