Sync peerId when we learn of it and make more robust