Annotation Interface NotifyBatch


@Target(TYPE) @Retention(RUNTIME) public @interface NotifyBatch
Enables batching of notifications. Requires setting size() and time() which control when the batched notifications will be sent to the listener.
Author:
kimchy
  • Required Element Summary

    Required Elements
    Modifier and Type
    Required Element
    Description
    int
    The batch size controls the number of notifications that will be sent in each batch.
    int
    The batch time controls the elapsed time until the batch buffer is cleared and sent.
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    boolean
    When batching is turned on, should the batch of events be passed as an Object[] to the listener.
    int
    The batch pending threshold controls the number of notifications that will be accumulated before they are sent.
  • Element Details

    • size

      int size
      The batch size controls the number of notifications that will be sent in each batch.
    • time

      int time
      The batch time controls the elapsed time until the batch buffer is cleared and sent. The time is in milliseconds.
    • pendingThreshold

      int pendingThreshold
      The batch pending threshold controls the number of notifications that will be accumulated before they are sent. If not set, size parameter will be used.
      Default:
      -1
    • passArrayAsIs

      boolean passArrayAsIs
      When batching is turned on, should the batch of events be passed as an Object[] to the listener. Default to false which means it will be passed one event at a time.
      Default:
      false