-
Notifications
You must be signed in to change notification settings - Fork 1
Load Testing
Load testing is not exactly encouraged (its actively discouraged in the FreeSWITCH community because so many people do it badly), but since a common concern with ACD platforms is scalability, OpenACD provides some load testing frameworks. These are primarily designed for identifying bottlenecks and crashes that only occur under high load, but may be useful when evaluating the platform.
The core module used for load testing OpenACD is ‘dummy_callcenter’, it is used to simulate inbound calls and to simulate agents receiving those calls.
No media testing is the simplest and it gives the clearest overview of the overhead of using OpenACD to route calls.
To invoke from the shell, pass it some arguments like this:
dummy_callcenter:start([{call_frequency, {distribution, 1}}, {agents, 50}, {call_max_life, {distribution, 180}}]).
This means to start a dummy callcenter with a call frequency of about 1 per second, 50 agents and a call duration of about 3 minutes. For other options, see dummy_callcenter.erl.
On my i7 macbook pro, this load generates 9 threads consuming < 10% cpu (out of 400% CPU, I believe).
Media testing sets up bots to push and answer calls through FreeSWITCH. It is geared toward evaluating load on a heavy system as well as network load.
The simplest set up requires two nodes, each with its own FreeSWITCH installation, ideally on separate hardware. One node will act as the call center, while the other will generate the calls (sip_bot node). On the call center node, set up OpenACD and FreeSWITCH as described in getting started.
On the sip_bot node, build OpenACD, then start an erl shell. Ensure the sip_bot node and OpenACD node can reach either other. Start cpxlog, then sib_bot_manager passing in the desired options. The easiest way to do so is by copying tests/sip_bot_config_example.hrl, editing it as desired, then starting the sib_bot_manager using that file.
Finally, use tests/sip_bot_manager_dialplan_example.xml as the base to configre the FreeSWITCH installation associated with the sip_bot node. The sip_bot_manager will begin making calls.
Much of this is explained (and makes more sense) in the two configuration files mentioned.