Class StreamsMetadata


  • @Evolving
    public class StreamsMetadata
    extends java.lang.Object
    Represents the state of an instance (process) in a KafkaStreams application. It contains the user supplied HostInfo that can be used by developers to build APIs and services to connect to other instances, the Set of state stores available on the instance and the Set of TopicPartitions available on the instance. NOTE: This is a point in time view. It may change when rebalances happen.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static StreamsMetadata NOT_AVAILABLE
      Sentinel to indicate that the StreamsMetadata is currently unavailable.
    • Constructor Summary

      Constructors 
      Constructor Description
      StreamsMetadata​(HostInfo hostInfo, java.util.Set<java.lang.String> stateStoreNames, java.util.Set<org.apache.kafka.common.TopicPartition> topicPartitions)  
    • Field Detail

      • NOT_AVAILABLE

        public static final StreamsMetadata NOT_AVAILABLE
        Sentinel to indicate that the StreamsMetadata is currently unavailable. This can occur during rebalance operations.
    • Constructor Detail

      • StreamsMetadata

        public StreamsMetadata​(HostInfo hostInfo,
                               java.util.Set<java.lang.String> stateStoreNames,
                               java.util.Set<org.apache.kafka.common.TopicPartition> topicPartitions)
    • Method Detail

      • stateStoreNames

        public java.util.Set<java.lang.String> stateStoreNames()
      • topicPartitions

        public java.util.Set<org.apache.kafka.common.TopicPartition> topicPartitions()
      • host

        public java.lang.String host()
      • port

        public int port()
      • 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
      • toString

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