Class HostInfo

    • Constructor Detail

      • HostInfo

        public HostInfo​(java.lang.String host,
                        int port)
    • Method Detail

      • buildFromEndpoint

        public static HostInfo buildFromEndpoint​(java.lang.String endPoint)
        Returns:
        a new HostInfo or null if endPoint is null or has no characters
        Throws:
        org.apache.kafka.common.config.ConfigException - if the host or port cannot be parsed from the given endpoint string
      • unavailable

        public static HostInfo unavailable()
        Returns:
        a sentinel for cases where the host metadata is currently unavailable, eg during rebalance operations.
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • host

        public java.lang.String host()
      • port

        public int port()
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object