A microservices-based platform for processing and managing Call Detail Records (CDRs) with real-time processing capabilities.
demo.mp4
The CDR Platform is designed to handle telecommunications activity logs (CDRs) with the following data structure:
- Source: The calling number (ANUM)
- Destination:
- For VOICE and SMS: the called number (BNUM)
- For DATA: the accessed URL
- StartTime: Timestamp of service initiation
- Service: One of VOICE, SMS, or DATA
- Usage:
- VOICE: minutes
- DATA: megabytes (MB)
- SMS: fixed value "1"
The platform consists of three main microservices:
- Processes CDR files in multiple formats (CSV, JSON, YAML, XML)
- Persists records to PostgreSQL
- Publishes events to Kafka for real-time processing
- Implements file validation and error handling
- Provides metrics and monitoring
- Built with Java 21 and Spring Boot 3.4
- Manages CDR records via RESTful APIs
- Secured with Keycloak (OAuth2/OpenID Connect)
- Consumes Kafka events for data synchronization
- Stores data in MySQL database
- React-based user interface
- Keycloak authentication integration
- CDR management and visualization
- Usage reporting and analytics
- Responsive Material-UI design
- Java 17 or higher
- Node.js 18 or higher
- Docker and Docker Compose
- PostgreSQL
- MySQL
- Kafka
- Keycloak
-
Clone the Repository:
git clone https://github.com/mahmoud-40/cdr-platform.git cd cdr-platform
-
Build and Start All Services:
# Build and start all services in one command docker-compose up --build
-
Access the Application:
- Frontend: http://localhost:8083
- Backend API: http://localhost:8082
- Loader Service: http://localhost:8081
- Keycloak: http://localhost:8080
- Kafdrop (Kafka UI): http://localhost:9000
If the backend or frontend services don't start properly, try restarting them:
# Restart backend service
docker-compose restart ms-backend
# Restart frontend service
docker-compose restart ms-frontend
cdr-platform/
├── ms-frontend/ # React frontend application
├── ms-backend/ # Spring Boot backend service
├── ms-loader/ # File processing service
├── docker-compose.yml # Docker Compose configuration
└── README.md # This file
-
Frontend:
cd ms-frontend npm install npm run dev
-
Backend:
cd ms-backend ./mvnw spring-boot:run
-
Loader:
cd ms-loader ./mvnw spring-boot:run
The platform is currently deployed using Docker Compose. Kubernetes deployment will be implemented in a future update.
Each service includes:
- Dockerfile for containerization
- Health checks and monitoring endpoints
- OAuth2/OpenID Connect authentication via Keycloak
- Secure API endpoints
- Role-based access control
- HTTPS support (to be configured)
Each service exposes monitoring endpoints:
- Health checks
- Metrics (Prometheus format)
- Application logs
- Fork the repository
- Create a feature branch
- Commit your changes
- Push to the branch
- Create a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.