Charging system is a telecom billing system residing in line with big data ecosystem. System listens to configured topics in Kafka server and does rating of events in real time.
Environment variables:
SPARK_HOME=D:\Softwares\Anaconda3\envs\billingEngine\Lib\site-packages\pyspark HADOOP_HOME=D:\Softwares\Anaconda3\envs\billingEngine\Lib\site-packages\pyspark
#winutils inside $HADOOP_HOME/bin for windows
#APP_HOME variable is used to identify location where config files are kept APP_HOME=D:\BillingEngine\Mediation
Configure $APP_HOME by setting the project directory in the IDE or "Environment Varibale" from the system.
Set the PYTHON_PATH in your project directory
Configure the kafka server:
-
Open the server.properties from kafka/config directory
-
Change the following ip addresses in : listeners, zookeeper.connect
Launching kafka in windows:
-
Start zookeeper: bin\windows\zookeeper-server-start.bat config/zookeeper.properties
-
Start kafka server: bin\windows\kafka-server-start.bat config\server.properties
-
Start producer:(Simulator for project/producer console for local testing) bin\windows\kafka-console-producer.bat --broker-list localhost:9092 --topic cdr-10
-
Start consumer: bin\windows\kafka-console-consumer.bat --bootstrap-server 207.23.221.244:9092 --topic cdr-10 --from-beginning
Starting Simulator:
-
Configure config.ini a) Set the server name : open cmd; type ipconfig; get the ip address and set it on the "SERVER_IP" b) Check the port or leave the default value of 9092 c) Customer list and cell tower locations must be present in the $APP_HOME/doc folder
-
Start the zookeeper(for windows only).
-
Start the kafka server
-
Open "producer.py" from "Charging_system\org\sfu\billing\simulator\controller"
-
Run "producer.py"
-
For debugging use the consumer command to check the message feeded on the kafka.
Starting Listener:
-
Create Conda environment checkend in billingEngine.yaml file
-
Add all relevant properties in config.ini file. These properties are self-explanatory