Class EventStream<K,​V>

  • Type Parameters:
    K - the record key type.
    V - the record value type.

    public class EventStream<K,​V>
    extends Object
    A typed stream of events backed by a BlockingRecordQueue.
    Since:
    0.8.0
    • Method Detail

      • type

        public String type()
        Returns:
        the name of the events send to this stream.
      • close

        public void close()
      • send

        public void send​(V value)
        Sends a key-value record into this queue.
        Parameters:
        value - the record value.
      • send

        public void send​(K key,
                         V value)
        Sends a key-value record into this stream.
        Parameters:
        key - the record key.
        value - the record value.
      • send

        public void send​(K key,
                         V value,
                         long timestamp)
        Sends a timestamped key-value record into this stream.
        Parameters:
        key - the record key.
        value - the record value.
      • send

        public void send​(KV<K,​V> kv)
        Sends a null-key value record into this stream.
        Parameters:
        kv - the KV record.