Fix deadlock in BlockManager reregistration triggered by failed updates.
Handle duplicate registrations better.
Merge pull request #418 from woggling/reregister-deadlock

Fix BlockManager reregistration deadlock; do BlockManager reregistration more asynchronously