org.apache.storm.topology

## Interface IStatefulWindowedBolt<T extends State>

- All Superinterfaces:
    IComponent, IStatefulComponent<T>, IWindowedBolt, Serializable
  All Known Implementing Classes:
    BaseStatefulWindowedBolt

      public interface IStatefulWindowedBolt<T extends State>
      extends IStatefulComponent<T>, IWindowedBolt

  A windowed bolt abstraction for supporting windowing operation with state.

- - ### Method Summary

    All Methods Instance Methods Default Methods
    Modifier and Type | Method and Description
    --- | ---
    `default boolean` | `isPersistent()` If the stateful windowed bolt should have its windows persisted in state and maintain a subset of events in memory.
    `default long` | `maxEventsInMemory()` The maximum number of window events to keep in memory.

    - ### Methods inherited from interface org.apache.storm.topology.IStatefulComponent

      `initState, preCommit, prePrepare, preRollback`

    - ### Methods inherited from interface org.apache.storm.topology.IWindowedBolt

      `cleanup, execute, getTimestampExtractor, prepare`

    - ### Methods inherited from interface org.apache.storm.topology.IComponent

      `declareOutputFields, getComponentConfiguration`

- - ### Method Detail

    - #### isPersistent

          default boolean isPersistent()

      If the stateful windowed bolt should have its windows persisted in state and maintain a subset of events in memory.

      The default is to keep all the window events in memory.

      Returns:
        true if the windows should be persisted

    - #### maxEventsInMemory

          default long maxEventsInMemory()

      The maximum number of window events to keep in memory.

Copyright © 2019 The Apache Software Foundation. All rights reserved.