In order to call wait() on an object, you have to hold the synchronized lock on that object (though the lock is actually released while the thread is waiting):
synchronized (serverAddr) {
serverAddr.wait();
}
I have to admit that why you're wanting to do this baffles me in this case...