int createdResourceId=-1;
// create child of eap6 as deployment
try {
CreateCBRRequest resource = new CreateCBRRequest();
resource.setParentId(as7Id);
resource.setResourceName("test-simple.war");
// type of the new resource
resource.setTypeName("Deployment");
resource.setPluginName("JBossAS7");
// set plugin config (path) and deploy config (runtime-name)
resource.getPluginConfig().put("path","deployment");
resource.getResourceConfig().put("runtimeName", DEPLOYED_WAR_NAME);
Response response =
given()
.body(resource) // Type of new resource
.queryParam("handle", handle)