code: public String getHost() {
      if (this.props.containsKey(ConfigurationKeys.AZKABAN_SERVER_HOST_NAME)) {
        final String hostName = this.props
            .getString(Constants.ConfigurationKeys.AZKABAN_SERVER_HOST_NAME);
        if (!StringUtils.isEmpty(hostName)) {
          return hostName;
        }
      }
  
      String host = "unkownHost";
      try {
        host = InetAddress.getLocalHost().getCanonicalHostName();
      } catch (final Exception e) {
        logger.error("Failed to fetch LocalHostName");
      }
      return host;
    }
docs: Get the hostname
  
  @return hostname