code: public static PackageManagerHttpActionException forIOException(String url, IOException ex) {
      String message = "HTTP call to " + url + " failed: "
          + StringUtils.defaultString(ex.getMessage(), ex.getClass().getSimpleName());
      if (ex instanceof SocketTimeoutException) {
        message += " (consider to increase the socket timeout using -Dvault.httpSocketTimeoutSec)";
      }
      return new PackageManagerHttpActionException(message, ex);
    }
docs: Create exception instance for I/O exception.
  @param url HTTP url called
  @param ex I/O exception
  @return Exception instance