code: public static String generateBasepath(final String ip, Short port) {
          if (isEmpty(ip)) {
              throw new IllegalArgumentException(NULL_SERVER_IP_MSG);
          }
          if (port == null) {
              port = 80;
          }
          StringBuilder basePath = new StringBuilder();
          basePath.append("http://").append(ip).append(":").append(port).append("/rest");
          return basePath.toString();
      }
docs: Generate the base path for the retina.
  
  @param ip : retina server ip.
  @param port : retina service port.
  @return : the retina's API base path.