@Test public void testJaxbToString() throws Exception { StageUtils stageUtils = new StageUtils(injector.getInstance(StageFactory.class)); Stage s = StageUtils.getATestStage(1, 2, "host1", "", "hostParamsStage"); String hostname = s.getHosts().get(0); List<ExecutionCommandWrapper> wrappers = s.getExecutionCommands(hostname); for (ExecutionCommandWrapper wrapper : wrappers) { } assertEquals(StageUtils.getActionId(1, 2), s.getActionId()); }
public static String jaxbToString(Object jaxbObj) throws JAXBException, JsonGenerationException, JsonMappingException, IOException { return getGson().toJson(jaxbObj); }
StageUtils { public static String jaxbToString(Object jaxbObj) throws JAXBException, JsonGenerationException, JsonMappingException, IOException { return getGson().toJson(jaxbObj); } }
StageUtils { public static String jaxbToString(Object jaxbObj) throws JAXBException, JsonGenerationException, JsonMappingException, IOException { return getGson().toJson(jaxbObj); } @Inject  StageUtils(StageFactory stageFactory); }
StageUtils { public static String jaxbToString(Object jaxbObj) throws JAXBException, JsonGenerationException, JsonMappingException, IOException { return getGson().toJson(jaxbObj); } @Inject  StageUtils(StageFactory stageFactory); static Gson getGson(); static void setGson(Gson gson); static void setTopologyManager(TopologyManager topologyManager); static void setConfiguration(Configuration configuration); static String getActionId(long requestId, long stageId); static Map<String, String> getComponentToClusterInfoKeyMap(); static long[] getRequestStage(String actionId); static Stage getATestStage(long requestId, long stageId, String clusterHostInfo, String commandParamsStage, String hostParamsStage); @Inject static Stage getATestStage(long requestId, long stageId, String hostname, String clusterHostInfo, String commandParamsStage, String hostParamsStage); static String jaxbToString(Object jaxbObj); static T fromJson(String json, Class<T> clazz); static Map<String, String> getCommandParamsStage(ActionExecutionContext actionExecContext); static Map<String, Set<String>> getClusterHostInfo(Cluster cluster); static Map<String, Set<String>> substituteHostIndexes(Map<String, Set<String>> clusterHostInfo); static Set<String> replaceRanges(SortedSet<Integer> set); static Set<String> replaceMappedRanges(List<T> values); static String getHostName(); }
StageUtils { public static String jaxbToString(Object jaxbObj) throws JAXBException, JsonGenerationException, JsonMappingException, IOException { return getGson().toJson(jaxbObj); } @Inject  StageUtils(StageFactory stageFactory); static Gson getGson(); static void setGson(Gson gson); static void setTopologyManager(TopologyManager topologyManager); static void setConfiguration(Configuration configuration); static String getActionId(long requestId, long stageId); static Map<String, String> getComponentToClusterInfoKeyMap(); static long[] getRequestStage(String actionId); static Stage getATestStage(long requestId, long stageId, String clusterHostInfo, String commandParamsStage, String hostParamsStage); @Inject static Stage getATestStage(long requestId, long stageId, String hostname, String clusterHostInfo, String commandParamsStage, String hostParamsStage); static String jaxbToString(Object jaxbObj); static T fromJson(String json, Class<T> clazz); static Map<String, String> getCommandParamsStage(ActionExecutionContext actionExecContext); static Map<String, Set<String>> getClusterHostInfo(Cluster cluster); static Map<String, Set<String>> substituteHostIndexes(Map<String, Set<String>> clusterHostInfo); static Set<String> replaceRanges(SortedSet<Integer> set); static Set<String> replaceMappedRanges(List<T> values); static String getHostName(); static final Integer DEFAULT_PING_PORT; static final String DEFAULT_RACK; static final String DEFAULT_IPV4_ADDRESS; }