public interface CustomPlugin
Modifier and Type | Method and Description |
---|---|
void |
abort(CustomPluginContext context,
java.util.List<RatedEventView> ratedEvents)
Abort allows plugin to abort the operation executed in the prepareCommit state
|
void |
commit(CustomPluginContext context,
java.util.List<RatedEventView> ratedEvents)
Commit allows plugin to commit the operation executed in the prepareCommit state
|
void |
initialize(FrameworkContext frameworkContext)
Initialization hook to allow custom plugin to execute tasks before processing rated events
|
void |
prepareCommit(CustomPluginContext context,
java.util.List<RatedEventView> ratedEvents)
Preparecommit allows plugin to operate against a list of rated events
in 2-phase stateful operation without commit the operation
|
void |
shutdown()
Upon stopping the rated event formatter, the shutdown will be invoked.
|
void initialize(FrameworkContext frameworkContext)
frameworkContext
- contains the RatedEventFormatter configuration and runtime informationvoid prepareCommit(CustomPluginContext context, java.util.List<RatedEventView> ratedEvents)
context
- A context keep track of the state of the 2-phase commit operation.
The context allows plugin to indicate success/failure from
executing from the prepareCommit operation.ratedEvents
- rated events to be processed by the custom pluginvoid commit(CustomPluginContext context, java.util.List<RatedEventView> ratedEvents)
context
- A context keep track of the state of the 2-phase commit operation
The context allows plugin to indicate success/failure from
executing from the commit operation.ratedEvents
- rated events to be committed by the custom pluginvoid abort(CustomPluginContext context, java.util.List<RatedEventView> ratedEvents)
context
- A context keep track of the state of the 2-phase commit operation
The context allows plugin to indicate success/failure from
executing from the abort operation.ratedEvents
- rated events to be aborted by the custom pluginvoid shutdown()