Class MultiKeyDispatcher<T extends com.fluxtion.api.StaticEventProcessor>

java.lang.Object
com.fluxtion.ext.streaming.api.group.MultiKeyDispatcher<T>
Type Parameters:
T -
All Implemented Interfaces:
com.fluxtion.api.StaticEventProcessor

public class MultiKeyDispatcher<T extends com.fluxtion.api.StaticEventProcessor>
extends java.lang.Object
implements com.fluxtion.api.StaticEventProcessor
Groups together StaticEventProcessor that have a shared MultiKey in a GroupBy node. If there are multiple StaticEventProcessor of the same type in different partitions this will index the StaticEventProcessor's and only dispatch events that match the multikey to the relevant instances.
Author:
Greg Higgins [email protected]
  • Field Summary

    Fields inherited from interface com.fluxtion.api.StaticEventProcessor

    NULL_EVENTHANDLER
  • Constructor Summary

    Constructors 
    Constructor Description
    MultiKeyDispatcher​(java.util.function.Function<T,​GroupBy> groupbyAccessor)  
  • Method Summary

    Modifier and Type Method Description
    void addToIndex​(T newCalc)  
    void index()  
    void onEvent​(java.lang.Object event)  
    void publish​(java.lang.Object event)  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • index

      public void index()
    • addToIndex

      public void addToIndex​(T newCalc)
    • onEvent

      public void onEvent​(java.lang.Object event)
      Specified by:
      onEvent in interface com.fluxtion.api.StaticEventProcessor
    • publish

      public void publish​(java.lang.Object event)