Use shared_handler in Socket, SocketWrapper
Remove needlesss template functions in Socket