1) Wrap the int in an Integer:
2) notifying may take a long time, that's the only problem. And if you are executing your code from a synchronized block / method, you could get possible deadlock problems (read Effective
Java to see how this is possible).
Not really Swing related, moving to beginner.