}
public CreateResourceReport createResource(CreateResourceReport report) {
JBossASServerComponent parentResourceComponent = (JBossASServerComponent) ctx.getParentResourceComponent();
Configuration config = report.getResourceConfiguration();
String name = report.getUserSpecifiedResourceName();
// String name = config.getSimple("MBeanName").getStringValue();
// PropertySimple nameTemplateProp = report.getPluginConfiguration().getSimple("nameTemplate");
// String rName = nameTemplateProp.getStringValue();
//noinspection ConstantConditions
// rName = rName.replace("{name}", name);
// TODO check for duplcicate name/mbean
// PropertySimple pluginNameProperty = new PropertySimple("name", rName);
// ctx.getPluginConfiguration().put(pluginNameProperty);
File deployDir = new File(parentResourceComponent.getConfigurationPath() + "/deploy");
File deploymentFile = new File(deployDir, FileNameUtility.formatFileName(name) + "-cache-service.xml");
String flavour = config.getSimple("Flavour").getStringValue();
boolean isTc = false;
if (flavour != null && flavour.startsWith("tree"))