Search in sources :

Example 1 with BlackholeAppServer

use of org.mobicents.tools.sip.balancer.BlackholeAppServer in project load-balancer by RestComm.

the class UdpForwardingPerformanceTest method setUp.

@Before
public void setUp() throws Exception {
    shootist = new Shootist();
    balancer = new BalancerRunner();
    LoadBalancerConfiguration lbConfig = new LoadBalancerConfiguration();
    lbConfig.getSipConfiguration().getExternalLegConfiguration().setHost("127.0.0.1");
    lbConfig.getSipConfiguration().getInternalLegConfiguration().setHost("127.0.0.1");
    lbConfig.getSipConfiguration().getInternalLegConfiguration().setUdpPort(5065);
    balancer.start(lbConfig);
    server = new BlackholeAppServer("blackhole", 18452, "127.0.0.1");
    server.start();
    Thread.sleep(5000);
}
Also used : BlackholeAppServer(org.mobicents.tools.sip.balancer.BlackholeAppServer) BalancerRunner(org.mobicents.tools.sip.balancer.BalancerRunner) LoadBalancerConfiguration(org.mobicents.tools.configuration.LoadBalancerConfiguration) Shootist(org.mobicents.tools.sip.balancer.operation.Shootist) Before(org.junit.Before)

Example 2 with BlackholeAppServer

use of org.mobicents.tools.sip.balancer.BlackholeAppServer in project load-balancer by RestComm.

the class TcpForwardingPerformanceTest method setUp.

@Before
public void setUp() throws Exception {
    balancer = new BalancerRunner();
    LoadBalancerConfiguration lbConfig = new LoadBalancerConfiguration();
    lbConfig.getSipConfiguration().getExternalLegConfiguration().setHost("127.0.0.1");
    lbConfig.getSipConfiguration().getInternalLegConfiguration().setHost("127.0.0.1");
    lbConfig.getSipConfiguration().getInternalLegConfiguration().setTcpPort(5065);
    balancer.start(lbConfig);
    server = new BlackholeAppServer("blackhole", 18452, "127.0.0.1");
    server.start();
    Thread.sleep(5000);
}
Also used : BlackholeAppServer(org.mobicents.tools.sip.balancer.BlackholeAppServer) BalancerRunner(org.mobicents.tools.sip.balancer.BalancerRunner) LoadBalancerConfiguration(org.mobicents.tools.configuration.LoadBalancerConfiguration) Before(org.junit.Before)

Aggregations

Before (org.junit.Before)2 LoadBalancerConfiguration (org.mobicents.tools.configuration.LoadBalancerConfiguration)2 BalancerRunner (org.mobicents.tools.sip.balancer.BalancerRunner)2 BlackholeAppServer (org.mobicents.tools.sip.balancer.BlackholeAppServer)2 Shootist (org.mobicents.tools.sip.balancer.operation.Shootist)1