Does anybody know why the method join() member of a java.lang.Thread was named like that? Its javadoc is:
Waits for this thread to die.
When join is called on some thread calling thread is waiting for the other to die and continue execution. Supposedly calling thread will die as well, but still it’s not clear why the author used this name.
It’s a common name in threading – it’s not like Java was the first to use it. (For example, that’s what pthreads uses too.)
I guess you could imagine it like two people taking a walk – you join the other one and walk with them until you’ve finished, before going back to what you were doing. That sort of analogy may have been the original reason, although I agree it’s not exactly intuitive.