Grouping with custom correlation
If you want to group your tuples and implement your own business logic to correlate the data tuples, you can configure your application easily to do so.
About this task
Enable file name or tuple attributes grouping and custom correlation.
Procedure
- In the file <PathToYourApplication>/config/config.cfg, find the ite.businessLogic.group parameter description
-
To enable the grouping function, set the parameter to on as follows: ite.businessLogic.group=on
-
In the file <PathToYourApplication>/config/config.cfg, find the ite.businessLogic.transformation.tupleGroupSplit and the ite.ingest.fileGroupSplit parameter descriptions
-
For grouping based on file names set the parameters as follows: ite.ingest.fileGroupSplit=on and ite.businessLogic.transformation.tupleGroupSplit=off, or for grouping based on tuple attributes set the parameters as follows: ite.ingest.fileGroupSplit=off and ite.businessLogic.transformation.tupleGroupSplit=on
-
In the file <PathToYourApplication>/config/config.cfg, find the ite.businessLogic.group.custom parameter description
-
To enable the custom correlation, set the parameter to on as follows: ite.businessLogic.group.custom=on
You need to implement your correlation logic in the <namespace>.context.custom::ContextDataProcessor composite operator.
For grouping based on tuple attributes, you implement your custom business logic in the <namespace>.chainprocessor.transfomer.custom::DataProcessor composite. The logic must produce a destination group ID in the groupID SPL output attribute. The groupID is a 2 digits rstring attribute that supports the range 00 - 99. The default groupID value is 00. If you set the groupID to an unknown value, then the Processing Element is going to shut down.