use of com.sequenceiq.cloudbreak.cloud.model.AmbariDatabase in project cloudbreak by hortonworks.
the class AmbariClusterSetupServiceTest method ambariDatabase.
private AmbariDatabase ambariDatabase() {
AmbariDatabase ambariDatabase = new AmbariDatabase();
ambariDatabase.setFancyName("mysql");
ambariDatabase.setHost("10.0.0.2");
ambariDatabase.setName("ambari-database");
ambariDatabase.setPassword("password123#$@");
ambariDatabase.setPort(3000);
ambariDatabase.setUserName("ambari-database-user");
ambariDatabase.setVendor("mysql");
return ambariDatabase;
}
use of com.sequenceiq.cloudbreak.cloud.model.AmbariDatabase in project cloudbreak by hortonworks.
the class StackToStackResponseConverterTest method setUp.
@Before
public void setUp() throws CloudbreakImageNotFoundException {
underTest = new StackToStackResponseConverter();
MockitoAnnotations.initMocks(this);
when(imageService.getImage(anyLong())).thenReturn(new Image("cb-centos66-amb200-2015-05-25", new HashMap<>(), "redhat6", "", "default", "default-id"));
when(componentConfigProvider.getCloudbreakDetails(anyLong())).thenReturn(new CloudbreakDetails("version"));
when(componentConfigProvider.getStackTemplate(anyLong())).thenReturn(new StackTemplate("{}", "version"));
when(clusterComponentConfigProvider.getHDPRepo(anyLong())).thenReturn(new StackRepoDetails());
when(clusterComponentConfigProvider.getAmbariDatabase(anyLong())).thenReturn(new AmbariDatabase());
when(clusterComponentConfigProvider.getAmbariRepo(anyLong())).thenReturn(new AmbariRepo());
}
use of com.sequenceiq.cloudbreak.cloud.model.AmbariDatabase in project cloudbreak by hortonworks.
the class BlueprintTemplateProcessorTest method ambariDatabase.
private AmbariDatabase ambariDatabase() {
AmbariDatabase ambariDatabase = new AmbariDatabase();
ambariDatabase.setFancyName("mysql");
ambariDatabase.setHost("10.0.0.2");
ambariDatabase.setName("ambari-database");
ambariDatabase.setPassword("password123#$@");
ambariDatabase.setPort(3000);
ambariDatabase.setUserName("ambari-database-user");
ambariDatabase.setVendor("mysql");
return ambariDatabase;
}
use of com.sequenceiq.cloudbreak.cloud.model.AmbariDatabase in project cloudbreak by hortonworks.
the class AmbariDatabaseMapperTest method testMapAmbariDatabaseToAmbariDatabaseDetailJson.
@Test
public void testMapAmbariDatabaseToAmbariDatabaseDetailJson() {
AmbariDatabase ambariDatabase = new AmbariDatabase();
ambariDatabase.setVendor(DatabaseVendor.POSTGRES.ambariVendor());
AmbariDatabaseDetailsJson ambariDatabaseDetailsJson = mapper.mapAmbariDatabaseToAmbariDatabaseDetailJson(ambariDatabase);
assertEquals(mapper.mapVendorByValue(DatabaseVendor.POSTGRES.ambariVendor()), ambariDatabaseDetailsJson.getVendor());
}
Aggregations