use of com.sequenceiq.cloudbreak.cmtemplate.CmTemplateProcessor in project cloudbreak by hortonworks.
the class SqlStreamBuilderAdminDatabaseConfigProviderTest method testConfigNeeded.
@Test
public void testConfigNeeded() {
CmTemplateProcessor cmTemplateProcessor = initTemplateProcessor("7.2.11");
TemplatePreparationObject preparationObject = initTemplatePreparationObject(cmTemplateProcessor);
assertTrue(underTest.isConfigurationNeeded(cmTemplateProcessor, preparationObject));
}
use of com.sequenceiq.cloudbreak.cmtemplate.CmTemplateProcessor in project cloudbreak by hortonworks.
the class SqlStreamBuilderAdminDatabaseConfigProviderTest method testNoConfigNeeded.
@Test
public void testNoConfigNeeded() {
CmTemplateProcessor cmTemplateProcessor = initTemplateProcessor("7.2.10");
TemplatePreparationObject preparationObject = initTemplatePreparationObject(cmTemplateProcessor);
assertFalse(underTest.isConfigurationNeeded(cmTemplateProcessor, preparationObject));
}
use of com.sequenceiq.cloudbreak.cmtemplate.CmTemplateProcessor in project cloudbreak by hortonworks.
the class SqlStreamBuilderSnapperDatabaseConfigProviderTest method testConfigNeeded.
@Test
public void testConfigNeeded() {
CmTemplateProcessor cmTemplateProcessor = initTemplateProcessor("7.2.11");
TemplatePreparationObject preparationObject = initTemplatePreparationObject(cmTemplateProcessor);
assertTrue(underTest.isConfigurationNeeded(cmTemplateProcessor, preparationObject));
}
use of com.sequenceiq.cloudbreak.cmtemplate.CmTemplateProcessor in project cloudbreak by hortonworks.
the class SqlStreamBuilderSnapperDatabaseConfigProviderTest method testProperSnapperDbConfig.
@Test
public void testProperSnapperDbConfig() {
CmTemplateProcessor cmTemplateProcessor = initTemplateProcessor("7.2.11");
TemplatePreparationObject preparationObject = initTemplatePreparationObject(cmTemplateProcessor);
List<ApiClusterTemplateConfig> roleConfigs = underTest.getRoleConfigs(SqlStreamBuilderRoles.MATERIALIZED_VIEW_ENGINE, preparationObject);
assertThat(roleConfigs).hasSameElementsAs(List.of(config("ssb.mve.datasource.url", "jdbc:postgresql://testhost:5432/eventador_snapper"), config("ssb.mve.datasource.username", "ssb_test_user"), config("ssb.mve.datasource.password", "ssb_test_pw")));
}
use of com.sequenceiq.cloudbreak.cmtemplate.CmTemplateProcessor in project cloudbreak by hortonworks.
the class TezRoleConfigProviderTest method validateClientConfig.
protected void validateClientConfig(String hmsExternalDirLocation, String protoDirLocation) {
TemplatePreparationObject preparationObject = getTemplatePreparationObject(hmsExternalDirLocation);
String inputJson = getBlueprintText("input/clouderamanager-ds.bp");
CmTemplateProcessor cmTemplateProcessor = new CmTemplateProcessor(inputJson);
Map<String, List<ApiClusterTemplateConfig>> roleConfigs = underTest.getRoleConfigs(cmTemplateProcessor, preparationObject);
List<ApiClusterTemplateConfig> tezConfigs = roleConfigs.get("tez-GATEWAY-BASE");
assertEquals(1, tezConfigs.size());
assertEquals("tez-conf/tez-site.xml_client_config_safety_valve", tezConfigs.get(0).getName());
assertEquals("<property><name>tez.history.logging.proto-base-dir</name><value>" + protoDirLocation + "</value></property>", tezConfigs.get(0).getValue());
}
Aggregations