docs: public static String generateHostHeader(URI uri) {
          String host = uri.getHost();
          if (isUsingNonDefaultPort(uri)) {
              host += ":" + uri.getPort();
          }
          return host;
      }