Package org.apache.storm.trident.windowing

# Interface ITridentWindowManager

All Known Implementing Classes:
  `AbstractTridentWindowManager`, `InMemoryTridentWindowManager`, `StoreBasedTridentWindowManager`

public interface ITridentWindowManager
Window manager to handle trident tuple events.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `addTuplesBatch(Object batchId, List<TridentTuple> tuples)`
  Add received batch of tuples to cache/store and add them to `WindowManager`.
  `Queue<org.apache.storm.trident.windowing.AbstractTridentWindowManager.TriggerResult>`
  `getPendingTriggers()`
  Returns pending triggers to be emitted.
  `void`
  `prepare()`
  This is invoked from `org.apache.storm.trident.planner.TridentProcessor`'s prepare method.
  `void`
  `shutdown()`
  This is invoked when from `org.apache.storm.trident.planner.TridentProcessor`'s cleanup method.

- ## Method Details

  - ### prepare

    void prepare()
    This is invoked from `org.apache.storm.trident.planner.TridentProcessor`'s prepare method. So any initialization tasks can be done before the topology starts accepting tuples. For ex: initialize window manager with any earlier stored tuples/triggers and start WindowManager.

  - ### shutdown

    void shutdown()
    This is invoked when from `org.apache.storm.trident.planner.TridentProcessor`'s cleanup method. So, any cleanup operations like clearing cache or close store connection etc can be done.

  - ### addTuplesBatch

    void addTuplesBatch(Object batchId, List<TridentTuple> tuples)
    Add received batch of tuples to cache/store and add them to `WindowManager`.

  - ### getPendingTriggers

    Queue<org.apache.storm.trident.windowing.AbstractTridentWindowManager.TriggerResult> getPendingTriggers()
    Returns pending triggers to be emitted.