Security: work around race condition between threads updating handshakers (#7251)
Security: work around race condition between threads updating handshakers (#7251)

Signed-off-by: Xintao <27e2221a3590bdf1c7193b8c94a0212f0bff29a3@live.com>
pingcap/tikv,BusyJay/tikv,c4pt0r/tikv,BusyJay/tikv,pingcap/tikv,BusyJay/tikv,BusyJay/tikv