Search in sources :

Example 1 with ZooKeeperConfiguration

use of com.hubspot.singularity.config.ZooKeeperConfiguration in project Singularity by HubSpot.

the class SingularityTestModule method getSingularityConfigurationForTestingServer.

private static SingularityConfiguration getSingularityConfigurationForTestingServer(final TestingServer ts) {
    SingularityConfiguration config = new SingularityConfiguration();
    config.setLoadBalancerUri("test");
    MesosConfiguration mc = new MesosConfiguration();
    mc.setDefaultCpus(1);
    mc.setDefaultMemory(128);
    mc.setDefaultDisk(1024);
    config.setMesosConfiguration(mc);
    config.setSmtpConfiguration(new SMTPConfiguration());
    ZooKeeperConfiguration zookeeperConfiguration = new ZooKeeperConfiguration();
    zookeeperConfiguration.setQuorum(ts.getConnectString());
    config.setZooKeeperConfiguration(zookeeperConfiguration);
    config.setConsiderTaskHealthyAfterRunningForSeconds(0);
    return config;
}
Also used : SMTPConfiguration(com.hubspot.singularity.config.SMTPConfiguration) MesosConfiguration(com.hubspot.singularity.config.MesosConfiguration) SingularityConfiguration(com.hubspot.singularity.config.SingularityConfiguration) ZooKeeperConfiguration(com.hubspot.singularity.config.ZooKeeperConfiguration)

Aggregations

MesosConfiguration (com.hubspot.singularity.config.MesosConfiguration)1 SMTPConfiguration (com.hubspot.singularity.config.SMTPConfiguration)1 SingularityConfiguration (com.hubspot.singularity.config.SingularityConfiguration)1 ZooKeeperConfiguration (com.hubspot.singularity.config.ZooKeeperConfiguration)1