DOCS-426 socket exception when primary steps down

Ready to merge.