}
private CreateResourceReport createConfigurationBasedResource(
CreateResourceReport createResourceReport) {
ResourceType resourceType = createResourceReport.getResourceType();
Configuration defaultPluginConfig = getDefaultPluginConfiguration(resourceType);
Configuration resourceConfig = createResourceReport
.getResourceConfiguration();
String resourceName = getResourceName(defaultPluginConfig,
resourceConfig);
ComponentType componentType = ProfileServiceUtil
.getComponentType(resourceType);
ManagementView managementView = null;
;
managementView = getConnection().getManagementView();
if (ProfileServiceUtil.isManagedComponent(getConnection(),
resourceName, componentType)) {
createResourceReport.setStatus(CreateResourceStatus.FAILURE);
createResourceReport.setErrorMessage("A " + resourceType.getName() //$NON-NLS-1$
+ " named '" + resourceName + "' already exists."); //$NON-NLS-1$ //$NON-NLS-2$
return createResourceReport;
}
createResourceReport.setResourceName(resourceName);
String resourceKey = getResourceKey(resourceType, resourceName);
createResourceReport.setResourceKey(resourceKey);
PropertySimple templateNameProperty = resourceConfig
.getSimple(TranslatorComponent.Config.TEMPLATE_NAME);
String templateName = templateNameProperty.getStringValue();
DeploymentTemplateInfo template;
try {