I try to use explicit waits whenever possible. Luckily, the Java client library provides a rich set of combinators for declaring them.
You can also define your own; they are basically functions from a WebDriver object to some other thing (usually a Boolean).
http://seleniumhq.github.io/selenium/docs/api/java/org/openq...