@Test public void testRecipePhaseExtract() { String example = "Name: /opt/scripts/recipe-runner.sh pre-cloudera-manager-start failing-recipe"; String result = recipeExecutionFailureHandler.getRecipePhase(example); assertEquals("pre-cloudera-manager-start", result); }
protected String getRecipePhase(String message) { Matcher matcher = PHASE_PATTERN.matcher(message); if (matcher.matches()) { return matcher.group(1); } return ""; }
RecipeExecutionFailureCollector { protected String getRecipePhase(String message) { Matcher matcher = PHASE_PATTERN.matcher(message); if (matcher.matches()) { return matcher.group(1); } return ""; } }
RecipeExecutionFailureCollector { protected String getRecipePhase(String message) { Matcher matcher = PHASE_PATTERN.matcher(message); if (matcher.matches()) { return matcher.group(1); } return ""; }  }
RecipeExecutionFailureCollector { protected String getRecipePhase(String message) { Matcher matcher = PHASE_PATTERN.matcher(message); if (matcher.matches()) { return matcher.group(1); } return ""; }  boolean canProcessExecutionFailure(CloudbreakOrchestratorException exception); List<RecipeFailure> collectErrors(CloudbreakOrchestratorException exception); Optional<InstanceMetaData> getInstanceMetadataByHost(Set<InstanceMetaData> instanceMetaData, String host); }
RecipeExecutionFailureCollector { protected String getRecipePhase(String message) { Matcher matcher = PHASE_PATTERN.matcher(message); if (matcher.matches()) { return matcher.group(1); } return ""; }  boolean canProcessExecutionFailure(CloudbreakOrchestratorException exception); List<RecipeFailure> collectErrors(CloudbreakOrchestratorException exception); Optional<InstanceMetaData> getInstanceMetadataByHost(Set<InstanceMetaData> instanceMetaData, String host);  }