-
Waleed Akbar authored
- README files of kpi manager/value writer/api are updated to reflect new changes.
Waleed Akbar authored- README files of kpi manager/value writer/api are updated to reflect new changes.
How to locally run and test KPI Value API micro-service
Pre-requisets
Ensure the following requirements are met before executing the KPI Value API service.
-
The KPI Manger service is running and Apache Kafka is running.
-
A virtual enviornment exist with all the required packages listed in "requirements.in" file sucessfully installed.
-
Call the "create_all_topics()" function to verify the existence of all required topics on kafka.
Messages format templates
The "messages" python file contains templates for creating gRPC messages.
Unit test file
The "KPI Value API test" python file enlist various tests conducted to validate functionality.
Flow of execution (Kpi Maanager Service functions)
-
Call the
create_new_topic_if_not_exists(<list of string>)
method to create any new topics if needed. -
Call
StoreKpiValues(KpiValueList)
to produceKpi Value
on a Kafka Topic. (TheKpiValueWriter
microservice will consume and process theKpi Value
) -
Call
SelectKpiValues(KpiValueFilter) -> KpiValueList
to read metric from the Prometheus DB.