code: func (p *ConnPool) getNewConn(dc string, addr net.Addr, version int, useTLS bool) (*Conn, error) {
  	// Get a new, raw connection.
  	conn, _, err := p.DialTimeout(dc, addr, defaultDialTimeout, useTLS)
  	if err != nil {
  		return nil, err
  	}
  
  	// Switch the multiplexing based on version
  	var session muxSession
  	if version < 2 {
  		conn.Close()
  		return nil, fmt.Errorf("cannot make client connection, unsupported protocol version %d", version)
  	}
  
  	// Write the Consul multiplex byte to set the mode
  	if _, err := conn.Write([]byte{byte(RPCMultiplexV2)}); err != nil {
  		conn.Close()
  		return nil, err
  	}
  
  	// Setup the logger
  	conf := yamux.DefaultConfig()
  	conf.LogOutput = p.LogOutput
  
  	// Create a multiplexed session
  	session, _ = yamux.Client(conn, conf)
  
  	// Wrap the connection
  	c := &Conn{
  		refCount: 1,
  		addr:     addr,
  		session:  session,
  		clients:  list.New(),
  		lastUsed: time.Now(),
  		version:  version,
  		pool:     p,
  	}
  	return c, nil
  }
docs: // getNewConn is used to return a new connection