static StratosAdminResponse deployCartridge (CartridgeDefinitionBean cartridgeDefinitionBean, ConfigurationContext ctxt,
String userName, String tenantDomain) throws RestAPIException {
log.info("Starting to deploy a Cartridge [type] "+cartridgeDefinitionBean.type);
CloudControllerServiceClient cloudControllerServiceClient = getCloudControllerServiceClient();
if (cloudControllerServiceClient != null) {
CartridgeConfig cartridgeConfig = PojoConverter.populateCartridgeConfigPojo(cartridgeDefinitionBean);
if(cartridgeConfig == null) {
throw new RestAPIException("Populated CartridgeConfig instance is null, cartridge deployment aborted");
}
// call CC
try {
cloudControllerServiceClient
.deployCartridgeDefinition(cartridgeConfig);
} catch (RemoteException e) {
log.error(e.getMessage(), e);
throw new RestAPIException(e.getMessage(), e);
} catch (CloudControllerServiceInvalidCartridgeDefinitionExceptionException e) {