You can define and send an event to test functional use cases of the Processing
Application.
About this task
Follow these steps to test the Processing Application you just created.
Procedure
-
Create a dedicated folder named
test-data.
- Inside
test-data create a test event named
event.json.
{
"id": "00001",
"timestamp": "2021-10-28T09:05:12.737Z",
"status": "ok"
}
- Send an event.
management-cli kafka producer-json --topic="icp4ba-bai-test-topic" --file="./test-data/event.json"
Note: The --topic value must match the topic name that is defined in section
Ingresses of processing-conf.json.
- Log in to the Business Performance Center.
- Create a new dashboard, named
Test application.
- Create a chart of type
Periodic Metric and named Event
status.
- Select the monitoring source:
test-monitoring-source - ALL.
- Add a group by
status.
- Create a chart, named
Data.
- In the Visualization tab, add data columns for each
property.
- Save your dashboard.
Results
Send an event, and watch Business Performance Center update the dashboard in
real-time.
What to do next
You can now clean all the resources after a deployment. See How to clean the
deployment of a Processing Application. You can also see Testing multiple events.