Commit after writing WaitNotify and deadLock example