CGRateS Architecture

The main reference for CGRateS Architecture can be found on the CGRateS Documentation site. This is a high-level summary.


CGRateS comprises a number of services which are designed to work together, but which can be run separately. There are some dependencies between these services so, that, for instance, running the CDR Server without the rater service doesn’t really make sense. But each service can be either run together with internal communication between services, or services can be executed separately with RPC calls between them across a network. This enables distribution and scaling of the system as required.

The primary services which make up the system are as follows:

  • Rating, Accounting, and LCR (RALs)
  • CDR Server
  • CDR Collector

There are also several secondary services which are also important:

  • Scheduler
  • Session Managers and Agents
  • PubSub Publish and subscribe service
  • CGR Stats
  • Aliases subsystem
  • Users subsystem
  • CDR Exporter

All of these services run within a “cgr-engine” instance. They can all run within the same cgr-engine instance and use internal communication between the services, or individual services can be separated into their own cgr-engine instances with RPC communication to other services.

The architecture is shown in the diagram below:

CGRateS Architecture






Leave a Reply

Your email address will not be published. Required fields are marked *