Added implementation for client connect