Add JSON configuration examples

Change-Id: I2b8f18163baf39d46b1abfed06987940f1e15bfe
Signed-off-by: Dirk Fauth <Dirk.Fauth@de.bosch.com>
diff --git a/manager/src/main/java/org/eclipse/app4mc/cloud/manager/CloudServiceExecutionRunnable.java b/manager/src/main/java/org/eclipse/app4mc/cloud/manager/CloudServiceExecutionRunnable.java
index d6a4517..ee6812d 100644
--- a/manager/src/main/java/org/eclipse/app4mc/cloud/manager/CloudServiceExecutionRunnable.java
+++ b/manager/src/main/java/org/eclipse/app4mc/cloud/manager/CloudServiceExecutionRunnable.java
@@ -172,7 +172,12 @@
 				statusUrl = HeaderHelper.getUrlFromLink(uploadResponse.getHeaders().get("Link"), "status", baseUrl);
 			} else {
 				// error
-				workflowStatus.addError("Upload to " + serviceName + " failed! Error code: " + uploadResponse.getStatus() + " - Workflow stopped!");
+				Object body = uploadResponse.getBody();
+				if (body != null && !body.toString().isEmpty()) {
+					workflowStatus.addError("Upload to " + serviceName + " failed! Error code: " + uploadResponse.getStatus() + " - " + body +" - Workflow stopped!");
+				} else {
+					workflowStatus.addError("Upload to " + serviceName + " failed! Error code: " + uploadResponse.getStatus() + " - Workflow stopped!");
+				}
 				return null;
 			}
 			
diff --git a/manager/src/main/java/org/eclipse/app4mc/cloud/manager/ServiceConfiguration.java b/manager/src/main/java/org/eclipse/app4mc/cloud/manager/ServiceConfiguration.java
index 5afe716..f113c98 100644
--- a/manager/src/main/java/org/eclipse/app4mc/cloud/manager/ServiceConfiguration.java
+++ b/manager/src/main/java/org/eclipse/app4mc/cloud/manager/ServiceConfiguration.java
@@ -46,7 +46,9 @@
 	}
 	
 	public List<ServiceConfigurationParameter> getParameterList() {
-		return this.parameter;
+		ArrayList<ServiceConfigurationParameter> params = new ArrayList<>(this.parameter);
+		params.sort((o1, o2) -> o1.getKey().compareTo(o2.getKey()));
+		return params;
 	}
 	
 	public ServiceConfigurationParameter getParameter(String key) {
diff --git a/manager/src/main/java/org/eclipse/app4mc/cloud/manager/WorkflowConfigController.java b/manager/src/main/java/org/eclipse/app4mc/cloud/manager/WorkflowConfigController.java
index a85fb56..591a0d5 100644
--- a/manager/src/main/java/org/eclipse/app4mc/cloud/manager/WorkflowConfigController.java
+++ b/manager/src/main/java/org/eclipse/app4mc/cloud/manager/WorkflowConfigController.java
@@ -59,6 +59,9 @@
 	
 	@Resource(name = "exampleModelFiles")
 	List<String> exampleModelFiles;
+	
+	@Resource(name = "exampleConfigFiles")
+	List<String> exampleConfigFiles;
 
 	@Autowired
 	private StorageService storageService;
@@ -68,27 +71,41 @@
 	
 	@Value("classpath:static/examples/*")
     private org.springframework.core.io.Resource[] exampleResources;
+	
+	@Value("classpath:static/example_configurations/*")
+	private org.springframework.core.io.Resource[] exampleConfigResources;
 
 	@GetMapping("/workflowConfig")
 	public String workflowConfig() {
 		return "workflowConfig";
 	}
 	
+	// TODO handle example config
+	
 	@PostMapping("/workflowConfig")
 	public String handleFileUpload(
 			@RequestParam(name = "file", required = false) MultipartFile file, 
 			@RequestParam(name = "example", required = false) String example, 
 			@RequestParam("configFile") MultipartFile configFile,
+			@RequestParam(name = "example_config", required = false) String example_config, 
 			RedirectAttributes redirectAttributes) {
 		
-		if (((file == null || file.isEmpty()) && StringUtils.isEmpty(example)) || configFile.isEmpty()) {
+		if (((file == null || file.isEmpty()) && StringUtils.isEmpty(example))) {
 			redirectAttributes.addFlashAttribute(
 					"message",
-					"You need to select an input file and a config file!");
+					"You need to select an input file or an example model!");
 
 			return "redirect:/workflowConfig";
 		}
 		
+		if (((configFile == null || configFile.isEmpty()) && StringUtils.isEmpty(example_config))) {
+			redirectAttributes.addFlashAttribute(
+					"message",
+					"You need to select a config file or an example configuration!");
+			
+			return "redirect:/workflowConfig";
+		}
+		
 		String uuid = null;
 		String filename = null;
 		String message = null;
@@ -104,16 +121,24 @@
 			message = filename + " example used";
 		}
 		
-		// upload the config file
-		this.storageService.store(uuid, configFile);
-		
-		// load the workflow status from config file
-		WorkflowStatus workflowStatus = WorkflowStatusHelper.loadWorkflowStatus(
-				this.storageService.load(uuid, configFile.getOriginalFilename()).toFile(), 
-				this.cloudServiceDefinitions);
-		
-		// add default service configurations if not specified
-		WorkflowStatusHelper.addDefaultConfigurations(workflowStatus);
+		WorkflowStatus workflowStatus = null;
+		if (configFile != null && !configFile.isEmpty()) {
+			// upload the config file
+			this.storageService.store(uuid, configFile);
+			
+			// load the workflow status from config file
+			workflowStatus = WorkflowStatusHelper.loadWorkflowStatus(
+					this.storageService.load(uuid, configFile.getOriginalFilename()).toFile(), 
+					this.cloudServiceDefinitions);
+		} else {
+			// copy the example configuration file
+			this.storageService.copyExample(uuid, example_config, exampleConfigResources);
+
+			// load the workflow status from config file
+			workflowStatus = WorkflowStatusHelper.loadWorkflowStatus(
+					this.storageService.load(uuid, example_config).toFile(), 
+					this.cloudServiceDefinitions);
+		}
 		
 		if (workflowStatus == null) {
 			redirectAttributes.addFlashAttribute(
@@ -123,6 +148,9 @@
 			return "redirect:/workflowConfig";
 		}
 		
+		// add default service configurations if not specified
+		WorkflowStatusHelper.addDefaultConfigurations(workflowStatus);
+		
 		workflowStatus.setUuid(uuid);
 		if (StringUtils.isEmpty(workflowStatus.getName())) {
 			// set a default name in case none was provided
@@ -155,6 +183,11 @@
 	public List<String> exampleModelFiles() {
 		return this.exampleModelFiles;
 	}
+	
+	@ModelAttribute("exampleConfigFiles")
+	public List<String> exampleConfigFiles() {
+		return this.exampleConfigFiles;
+	}
 
 	@ExceptionHandler(StorageFileNotFoundException.class)
 	public ResponseEntity<?> handleStorageFileNotFound(StorageFileNotFoundException exc) {
diff --git a/manager/src/main/java/org/eclipse/app4mc/cloud/manager/administration/ApplicationConfig.java b/manager/src/main/java/org/eclipse/app4mc/cloud/manager/administration/ApplicationConfig.java
index 7767f33..263d549 100644
--- a/manager/src/main/java/org/eclipse/app4mc/cloud/manager/administration/ApplicationConfig.java
+++ b/manager/src/main/java/org/eclipse/app4mc/cloud/manager/administration/ApplicationConfig.java
@@ -1,5 +1,5 @@
 /*********************************************************************************
- * Copyright (c) 2020 Robert Bosch GmbH and others.
+ * Copyright (c) 2020, 2021 Robert Bosch GmbH and others.
  *
  * This program and the accompanying materials are made
  * available under the terms of the Eclipse Public License 2.0
@@ -37,6 +37,9 @@
 	@Value("classpath:static/examples/*")
     private Resource[] exampleResources;
 	
+	@Value("classpath:static/example_configurations/*")
+	private Resource[] exampleConfigResources;
+	
 	@Bean
     @ApplicationScope
     public WorkflowStatusMap workflowStatusMap() {
@@ -88,4 +91,18 @@
 		
 		return examples;
 	}
+	
+	@Bean
+	@ApplicationScope
+	public List<String> exampleConfigFiles() {
+		List<String> examples = new ArrayList<>();
+		
+		if (exampleConfigResources != null) {
+			examples = Arrays.stream(exampleConfigResources).map(Resource::getFilename).collect(Collectors.toList());
+		}
+		
+		Collections.sort(examples, String.CASE_INSENSITIVE_ORDER);
+		
+		return examples;
+	}
 }
diff --git a/manager/src/main/java/org/eclipse/app4mc/cloud/manager/storage/FileSystemStorageService.java b/manager/src/main/java/org/eclipse/app4mc/cloud/manager/storage/FileSystemStorageService.java
index 7ddde78..d3a325f 100644
--- a/manager/src/main/java/org/eclipse/app4mc/cloud/manager/storage/FileSystemStorageService.java
+++ b/manager/src/main/java/org/eclipse/app4mc/cloud/manager/storage/FileSystemStorageService.java
@@ -1,5 +1,5 @@
 /*********************************************************************************
- * Copyright (c) 2020 Robert Bosch GmbH and others.
+ * Copyright (c) 2020, 2021 Robert Bosch GmbH and others.
  *
  * This program and the accompanying materials are made
  * available under the terms of the Eclipse Public License 2.0
@@ -146,6 +146,22 @@
 			// extract uuid from pathname
 			String uuid = path.toString().substring(path.toString().lastIndexOf('_') + 1);
 			
+			copyExample(path, filename, exampleResources);
+			
+			return uuid;
+		} catch (IOException e) {
+			throw new StorageException("Failed to copy example file " + filename, e);
+		}
+	}
+	
+	@Override
+	public void copyExample(String uuid, String filename, Resource[] exampleResources) {
+		Path path = this.tempLocation.resolve(TEMP_DIR_PREFIX + uuid);
+		copyExample(path, filename, exampleResources);
+	}
+	
+	private void copyExample(Path path, String filename, Resource[] exampleResources) {
+		try {
 			Resource resource = Arrays.stream(exampleResources)
 					.filter(res -> filename.equals(res.getFilename()))
 					.findFirst()
@@ -155,8 +171,6 @@
 			} else {
 				throw new StorageException("Could not access example file " + filename);
 			}
-			
-			return uuid;
 		} catch (IOException e) {
 			throw new StorageException("Failed to copy example file " + filename, e);
 		}
diff --git a/manager/src/main/java/org/eclipse/app4mc/cloud/manager/storage/StorageService.java b/manager/src/main/java/org/eclipse/app4mc/cloud/manager/storage/StorageService.java
index 43f7d15..09465fd 100644
--- a/manager/src/main/java/org/eclipse/app4mc/cloud/manager/storage/StorageService.java
+++ b/manager/src/main/java/org/eclipse/app4mc/cloud/manager/storage/StorageService.java
@@ -1,5 +1,5 @@
 /*********************************************************************************
- * Copyright (c) 2020 Robert Bosch GmbH and others.
+ * Copyright (c) 2020, 2021 Robert Bosch GmbH and others.
  *
  * This program and the accompanying materials are made
  * available under the terms of the Eclipse Public License 2.0
@@ -38,5 +38,7 @@
 
 	String copyExample(String filename, Resource[] exampleResources);
 	
+	void copyExample(String uuid, String filename, Resource[] exampleResources);
+	
 	Resource getResultArchive(String uuid) throws IOException;
 }
diff --git a/manager/src/main/resources/static/example_configurations/all_label_interpreter_mixed.json b/manager/src/main/resources/static/example_configurations/all_label_interpreter_mixed.json
new file mode 100644
index 0000000..cec729a
--- /dev/null
+++ b/manager/src/main/resources/static/example_configurations/all_label_interpreter_mixed.json
@@ -0,0 +1,25 @@
+{
+  "name" : "All Label Interpreter - Mixed Workflow",
+  "services" : {
+    "migration" : { },
+    "validation" : {
+      "profiles" : "Amalthea Standard Validations",
+	  "label_core_chart" : {
+	    "label_core_interpreter" : { },
+		"chart_visualizer" : { }
+	  },
+	  "label_memory_chart" : {
+	    "label_memory_interpreter" : { },
+		"chart_visualizer" : { }
+	  },
+	  "label_task_chart" : {
+	    "label_task_interpreter" : { },
+		"chart_visualizer" : { }
+	  },
+	  "label_size_chart" : {
+	    "label_size_interpreter" : { },
+		"chart_visualizer" : { }
+	  }
+	}
+  }
+}
\ No newline at end of file
diff --git a/manager/src/main/resources/static/example_configurations/all_label_interpreter_tree.json b/manager/src/main/resources/static/example_configurations/all_label_interpreter_tree.json
new file mode 100644
index 0000000..d48d4c7
--- /dev/null
+++ b/manager/src/main/resources/static/example_configurations/all_label_interpreter_tree.json
@@ -0,0 +1,21 @@
+{
+  "name" : "All Label Interpreter - Tree Workflow",
+  "services" : {
+    "migration" : {
+      "validation" : {
+        "label_core_interpreter" : {
+          "chart_visualizer" : { }
+        },
+        "label_memory_interpreter" : {
+          "chart_visualizer" : { }
+        },
+        "label_task_interpreter" : {
+          "chart_visualizer" : { }
+        },
+        "label_size_interpreter" : {
+          "chart_visualizer" : { }
+        }
+      }
+    }
+  }
+}
\ No newline at end of file
diff --git a/manager/src/main/resources/static/example_configurations/all_services_mixed.json b/manager/src/main/resources/static/example_configurations/all_services_mixed.json
new file mode 100644
index 0000000..955d7fe
--- /dev/null
+++ b/manager/src/main/resources/static/example_configurations/all_services_mixed.json
@@ -0,0 +1,40 @@
+{
+  "name" : "All Services - Mixed Workflow",
+  "services" : {
+    "migration" : { },
+    "validation" : {
+      "profiles" : "Amalthea Standard Validations",
+	  "label_core_chart" : {
+	    "label_core_interpreter" : { },
+		"chart_visualizer" : { }
+	  },
+	  "label_memory_chart" : {
+	    "label_memory_interpreter" : { },
+		"chart_visualizer" : { }
+	  },
+	  "label_task_chart" : {
+	    "label_task_interpreter" : { },
+		"chart_visualizer" : { }
+	  },
+	  "label_size_chart" : {
+	    "label_size_interpreter" : { },
+		"chart_visualizer" : { }
+	  },
+	  "rtc_analysis_chart" : {
+        "rtc_analysis" : {
+          "analysis-ignore-overutilization" : "true",
+          "analysis-time-unit" : ""
+        },
+        "rtc_interpreter" : { },
+	    "chart_visualizer" : { }
+	  },
+	  "systemc_simulation" : {
+        "amlt2systemc" : { },
+        "app4mc_sim" : {
+	        "timeout" : "-1"
+	    },
+        "inchron_btf_visualization" : { }
+	  }
+	}
+  }
+}
\ No newline at end of file
diff --git a/manager/src/main/resources/static/example_configurations/all_services_tree.json b/manager/src/main/resources/static/example_configurations/all_services_tree.json
new file mode 100644
index 0000000..558f89e
--- /dev/null
+++ b/manager/src/main/resources/static/example_configurations/all_services_tree.json
@@ -0,0 +1,34 @@
+{
+  "name" : "All Services - Tree Workflow",
+  "services" : {
+    "migration" : {
+      "validation" : {
+        "label_core_interpreter" : {
+          "chart_visualizer" : { }
+        },
+        "label_memory_interpreter" : {
+          "chart_visualizer" : { }
+        },
+        "label_task_interpreter" : {
+          "chart_visualizer" : { }
+        },
+        "label_size_interpreter" : {
+          "chart_visualizer" : { }
+        },
+        "rtc_analysis" : {
+          "analysis-ignore-overutilization" : "true",
+          "analysis-time-unit" : "",
+          "rtc_interpreter" : {
+            "chart_visualizer" : { }
+          }
+        },
+        "amlt2systemc" : {
+          "app4mc_sim" : {
+	        "timeout" : "-1",
+            "inchron_btf_visualization" : { }
+	      }
+		}
+      }
+    }
+  }
+}
\ No newline at end of file
diff --git a/manager/src/main/resources/static/example_configurations/rtc_analysis_sequential.json b/manager/src/main/resources/static/example_configurations/rtc_analysis_sequential.json
new file mode 100644
index 0000000..f6cc349
--- /dev/null
+++ b/manager/src/main/resources/static/example_configurations/rtc_analysis_sequential.json
@@ -0,0 +1,13 @@
+{
+  "name" : "RTC Analysis - Sequential Workflow",
+  "services" : {
+    "migration" : { },
+    "validation" : { },
+    "rtc_analysis" : {
+      "analysis-ignore-overutilization" : "true",
+      "analysis-time-unit" : ""
+    },
+    "rtc_interpreter" : { },
+	"chart_visualizer" : { }
+  }
+}
\ No newline at end of file
diff --git a/manager/src/main/resources/static/example_configurations/systemc_simulation_sequential.json b/manager/src/main/resources/static/example_configurations/systemc_simulation_sequential.json
new file mode 100644
index 0000000..95d3094
--- /dev/null
+++ b/manager/src/main/resources/static/example_configurations/systemc_simulation_sequential.json
@@ -0,0 +1,12 @@
+{
+  "name" : "Sequential Workflow",
+  "services" : {
+    "migration" : { },
+    "validation" : { },
+    "label_core_interpreter" : {
+      "timeout" : "360000",
+	  "deleteResult" : "true"
+	},
+	"chart_visualizer" : { }
+  }
+}
\ No newline at end of file
diff --git a/manager/src/main/resources/templates/index.html b/manager/src/main/resources/templates/index.html
index fddb0cd..9293d64 100644
--- a/manager/src/main/resources/templates/index.html
+++ b/manager/src/main/resources/templates/index.html
@@ -45,7 +45,7 @@
 		      </div>
 		      <div class="match-height-item-by-row col-sm-6" align="center">
 		        <p id="copyright-text">Panorama is an <a href="https://itea3.org/">ITEA3</a> Project and supported by <a href="https://www.bmbf.de">BMBF</a> in Germany</p>
-		        <a href="https://www.bmbf.de/"> <img src="/images/bmbf.svg" class="img-responsive" alt="BMBF" width="200"></a>
+		        <a href="https://www.bmbf.de/"> <img src="/images/bmbf.svg" class="img-responsive" alt="BMBF" width="150"></a>
 		        <p class="pt-1">Copyright &copy; PANORAMA project partners. <br />All Rights Reserved.</p>
 		      </div>
 		      <div class="col-sm-3">
diff --git a/manager/src/main/resources/templates/workflowConfig.html b/manager/src/main/resources/templates/workflowConfig.html
index bfbe613..097c3ce 100644
--- a/manager/src/main/resources/templates/workflowConfig.html
+++ b/manager/src/main/resources/templates/workflowConfig.html
@@ -33,7 +33,7 @@
 					name="example" 
 					id="example" 
 					class="form-control">
-					<option value="" disabled selected hidden="true">Select one of the provided examples</option>
+					<option value="" disabled selected hidden="true">Select one of the provided example models</option>
 				    <option 
 				    	th:each="ex : ${exampleModelFiles}" 
 				    	th:text="${ex}" 
@@ -41,7 +41,7 @@
 				    </option>
 				</select><br>
 				<small id="inputHelpBlock" class="form-text text-muted">
-					Either upload a file to process or use one of the provided example model files.
+					Either upload a model file to process or use one of the provided example model files.
 				</small>
 			</div>
 			<div class="form-row mb-3">
@@ -57,6 +57,22 @@
 					Upload a JSON config file that provides the process configuration.
 				</small>
 			</div>
+			<div class="form-row mb-3">
+				<select 
+					name="example_config" 
+					id="example_config" 
+					class="form-control">
+					<option value="" disabled selected hidden="true">Select one of the provided example configurations</option>
+				    <option 
+				    	th:each="ex : ${exampleConfigFiles}" 
+				    	th:text="${ex}" 
+				    	th:value="${ex}">
+				    </option>
+				</select><br>
+				<small id="inputConfigHelpBlock" class="form-text text-muted">
+					Either upload a configuration file to process or use one of the provided example configuration files.
+				</small>
+			</div>
 			<div id="buttons" class="form-row" style="margin-top: 20px; margin-bottom: 100px">
 				<div class="col text-center">
 					<input 
diff --git a/manager/src/test/java/org/eclipse/app4mc/cloud/manager/WorkflowStatusHelperTest.java b/manager/src/test/java/org/eclipse/app4mc/cloud/manager/WorkflowStatusHelperTest.java
index d0da101..c9994d4 100644
--- a/manager/src/test/java/org/eclipse/app4mc/cloud/manager/WorkflowStatusHelperTest.java
+++ b/manager/src/test/java/org/eclipse/app4mc/cloud/manager/WorkflowStatusHelperTest.java
@@ -85,8 +85,8 @@
 		simpleChainBuilder.append("  \"uuid\" : \"1234\",").append(System.lineSeparator());
 		simpleChainBuilder.append("  \"services\" : {").append(System.lineSeparator());
 		simpleChainBuilder.append("    \"label_core_interpreter\" : {").append(System.lineSeparator());
-		simpleChainBuilder.append("      \"timeout\" : \"360000\",").append(System.lineSeparator());
-		simpleChainBuilder.append("      \"deleteResult\" : \"false\"").append(System.lineSeparator());
+		simpleChainBuilder.append("      \"deleteResult\" : \"false\",").append(System.lineSeparator());
+		simpleChainBuilder.append("      \"timeout\" : \"360000\"").append(System.lineSeparator());
 		simpleChainBuilder.append("    },").append(System.lineSeparator());
 		simpleChainBuilder.append("    \"chart_visualizer\" : { }").append(System.lineSeparator());
 		simpleChainBuilder.append("  },").append(System.lineSeparator());
@@ -105,11 +105,11 @@
 		allNestedBuilder.append("{").append(System.lineSeparator());
 		allNestedBuilder.append("  \"services\" : {").append(System.lineSeparator());
 		allNestedBuilder.append("    \"migration\" : {").append(System.lineSeparator());
-		allNestedBuilder.append("      \"timeout\" : \"60000\",").append(System.lineSeparator());
 		allNestedBuilder.append("      \"deleteResult\" : \"true\",").append(System.lineSeparator());
+		allNestedBuilder.append("      \"timeout\" : \"60000\",").append(System.lineSeparator());
 		allNestedBuilder.append("      \"validation\" : {").append(System.lineSeparator());
-		allNestedBuilder.append("        \"timeout\" : \"60000\",").append(System.lineSeparator());
 		allNestedBuilder.append("        \"deleteResult\" : \"true\",").append(System.lineSeparator());
+		allNestedBuilder.append("        \"timeout\" : \"60000\",").append(System.lineSeparator());
 		allNestedBuilder.append("        \"label_core_interpreter\" : { }").append(System.lineSeparator());
 		allNestedBuilder.append("      }").append(System.lineSeparator());
 		allNestedBuilder.append("    }").append(System.lineSeparator());
@@ -124,38 +124,38 @@
 		structuredNestedBuilder.append("  \"uuid\" : \"1234\",").append(System.lineSeparator());
 		structuredNestedBuilder.append("  \"services\" : {").append(System.lineSeparator());
 		structuredNestedBuilder.append("    \"migration\" : {").append(System.lineSeparator());
-		structuredNestedBuilder.append("      \"timeout\" : \"60000\",").append(System.lineSeparator());
-		structuredNestedBuilder.append("      \"deleteResult\" : \"true\"").append(System.lineSeparator());
+		structuredNestedBuilder.append("      \"deleteResult\" : \"true\",").append(System.lineSeparator());
+		structuredNestedBuilder.append("      \"timeout\" : \"60000\"").append(System.lineSeparator());
 		structuredNestedBuilder.append("    },").append(System.lineSeparator());
 		structuredNestedBuilder.append("    \"validation\" : {").append(System.lineSeparator());
-		structuredNestedBuilder.append("      \"timeout\" : \"60000\",").append(System.lineSeparator());
 		structuredNestedBuilder.append("      \"deleteResult\" : \"true\",").append(System.lineSeparator());
 		structuredNestedBuilder.append("      \"profiles\" : \"Amalthea Standard Validations\",").append(System.lineSeparator());
+		structuredNestedBuilder.append("      \"timeout\" : \"60000\",").append(System.lineSeparator());
 		structuredNestedBuilder.append("      \"label_core_chart\" : {").append(System.lineSeparator());
 		structuredNestedBuilder.append("        \"label_core_interpreter\" : {").append(System.lineSeparator());
-		structuredNestedBuilder.append("          \"timeout\" : \"360000\",").append(System.lineSeparator());
-		structuredNestedBuilder.append("          \"deleteResult\" : \"false\"").append(System.lineSeparator());
+		structuredNestedBuilder.append("          \"deleteResult\" : \"false\",").append(System.lineSeparator());
+		structuredNestedBuilder.append("          \"timeout\" : \"360000\"").append(System.lineSeparator());
 		structuredNestedBuilder.append("        },").append(System.lineSeparator());
 		structuredNestedBuilder.append("        \"chart_visualizer\" : { }").append(System.lineSeparator());
 		structuredNestedBuilder.append("      },").append(System.lineSeparator());
 		structuredNestedBuilder.append("      \"label_memory_chart\" : {").append(System.lineSeparator());
 		structuredNestedBuilder.append("        \"label_memory_interpreter\" : {").append(System.lineSeparator());
-		structuredNestedBuilder.append("          \"timeout\" : \"60000\",").append(System.lineSeparator());
-		structuredNestedBuilder.append("          \"deleteResult\" : \"true\"").append(System.lineSeparator());
+		structuredNestedBuilder.append("          \"deleteResult\" : \"true\",").append(System.lineSeparator());
+		structuredNestedBuilder.append("          \"timeout\" : \"60000\"").append(System.lineSeparator());
 		structuredNestedBuilder.append("        },").append(System.lineSeparator());
 		structuredNestedBuilder.append("        \"chart_visualizer\" : { }").append(System.lineSeparator());
 		structuredNestedBuilder.append("      },").append(System.lineSeparator());
 		structuredNestedBuilder.append("      \"label_task_chart\" : {").append(System.lineSeparator());
 		structuredNestedBuilder.append("        \"label_task_interpreter\" : {").append(System.lineSeparator());
-		structuredNestedBuilder.append("          \"timeout\" : \"60000\",").append(System.lineSeparator());
-		structuredNestedBuilder.append("          \"deleteResult\" : \"true\"").append(System.lineSeparator());
+		structuredNestedBuilder.append("          \"deleteResult\" : \"true\",").append(System.lineSeparator());
+		structuredNestedBuilder.append("          \"timeout\" : \"60000\"").append(System.lineSeparator());
 		structuredNestedBuilder.append("        },").append(System.lineSeparator());
 		structuredNestedBuilder.append("        \"chart_visualizer\" : { }").append(System.lineSeparator());
 		structuredNestedBuilder.append("      },").append(System.lineSeparator());
 		structuredNestedBuilder.append("      \"label_size_chart\" : {").append(System.lineSeparator());
 		structuredNestedBuilder.append("        \"label_size_interpreter\" : {").append(System.lineSeparator());
-		structuredNestedBuilder.append("          \"timeout\" : \"60000\",").append(System.lineSeparator());
-		structuredNestedBuilder.append("          \"deleteResult\" : \"true\"").append(System.lineSeparator());
+		structuredNestedBuilder.append("          \"deleteResult\" : \"true\",").append(System.lineSeparator());
+		structuredNestedBuilder.append("          \"timeout\" : \"60000\"").append(System.lineSeparator());
 		structuredNestedBuilder.append("        },").append(System.lineSeparator());
 		structuredNestedBuilder.append("        \"chart_visualizer\" : { }").append(System.lineSeparator());
 		structuredNestedBuilder.append("      }").append(System.lineSeparator());