You must satisfy the IWindowedBolt and IComponent interfaces.
BaseWindowedBolt is there for your convenience. When constructing the
topology, there is a setBolt method on TopologyBuilder specifically for
bolts satisfying the IWindowedBolt interface. It will be wrapped with a
WindowedBoltExecutor by the TopologyBuilder for you. You can implement
windows yourself by returning a HashMap from getComponentConfiguration in
your custom bolt (as long as they also implement the IWindowedBolt
interface).

On Wed, Dec 21, 2016 at 12:30 PM, Matt Foley <[email protected]> wrote:

> Hi, I’ve been unable to find this in the Storm documentation:
>
>
>
> How does the Storm topology loader identify if a Bolt is a “windowing”
> bolt and therefore needs to be wrapped with WindowedBoltExecutor?  Does it
> look at:
>
> 1.      Whether the Bolt’s getComponentConfiguration() method presents
> some or all of the windowing-related configuration parameters, as
> BaseWindowedBolt does;
>
> 2.      Or does it use reflection to determine if the Bolt implements
> IWindowedBolt interface;
>
> 3.      Or does the Bolt actually have to extend BaseWindowedBolt?
>
>
>
> There are indications in the docs that it is #2, but I wasn’t able to
> become certain.  Please clarify.
>
> Thanks,
>
> --Matt
>
>
>

Reply via email to