> For the complete documentation index, see [llms.txt](https://docs.cennso.com/components/cdf/3.1/llms.txt) (all documentation: [llms.txt](https://docs.cennso.com/llms.txt)). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cennso.com/components/cdf/3.1/scaling.md).

# Scaling

You can scale CDF to increase the number of receivers from which the sender gets CDR files. CDF configuration is changed by deploying a new CDF.

To scale CDF, perform these steps in any order:

* Deploy a new receiver with a unique S3 directory.
* Stop the current sender and restart with a new configuration including all S3 directories that are used by the receivers.

## Receiver

When deploying a new receiver, the Helm chart value of the **receiver.directory** parameter must be unique. All receivers must have the same S3 configuration (endpoint, bucket). The sender can only get CDR files from one S3 bucket.

One CPU and 1 GB RAM allow a receiver to handle 2,000 CDRs per second. A lower rate needs less resources.

## Sender

There is only one sender. The sender must have the same S3 configuration (endpoint, bucket) as all receivers. Only CDR files from the directories configured with the **sender.directories** parameter are downloaded and used for sending.

This is a sample configuration of sender directories for all working receivers:

``` yaml
receiver:
  enabled: true
  directory: receiver1
---------------------
receiver:
  enabled: true
  directory: receiver2
---------------------
sender:
  enabled: true
  directories:
    - receiver1
    - receiver2
```

One CPU and 1 GB RAM allow the sender to handle 1,000 CDRs per second. CDR files from only one receiver were needed for this. The sender can reach 1,700 CDRs per second if it has two receivers feeding it CDR files via S3. The sender had 2 CPU and 2 GB RAM for this.
