@Test(timeout = 10000) public void testAccurateProcessListReturned() throws Exception { Map<ServerType,Collection<ProcessReference>> procs = accumulo.getProcesses(); assertTrue(procs.containsKey(ServerType.GARBAGE_COLLECTOR)); for (ServerType t : new ServerType[] {ServerType.MANAGER, ServerType.TABLET_SERVER, ServerType.ZOOKEEPER}) { assertTrue(procs.containsKey(t)); Collection<ProcessReference> procRefs = procs.get(t); assertTrue(1 <= procRefs.size()); for (ProcessReference procRef : procRefs) { assertNotNull(procRef); } } }
public Map<ServerType,Collection<ProcessReference>> getProcesses() { Map<ServerType,Collection<ProcessReference>> result = new HashMap<>(); MiniAccumuloClusterControl control = getClusterControl(); result.put(ServerType.MANAGER, references(control.masterProcess)); result.put(ServerType.TABLET_SERVER, references(control.tabletServerProcesses.toArray(new Process[0]))); if (control.zooKeeperProcess != null) { result.put(ServerType.ZOOKEEPER, references(control.zooKeeperProcess)); } if (control.gcProcess != null) { result.put(ServerType.GARBAGE_COLLECTOR, references(control.gcProcess)); } return result; }
MiniAccumuloClusterImpl implements AccumuloCluster { public Map<ServerType,Collection<ProcessReference>> getProcesses() { Map<ServerType,Collection<ProcessReference>> result = new HashMap<>(); MiniAccumuloClusterControl control = getClusterControl(); result.put(ServerType.MANAGER, references(control.masterProcess)); result.put(ServerType.TABLET_SERVER, references(control.tabletServerProcesses.toArray(new Process[0]))); if (control.zooKeeperProcess != null) { result.put(ServerType.ZOOKEEPER, references(control.zooKeeperProcess)); } if (control.gcProcess != null) { result.put(ServerType.GARBAGE_COLLECTOR, references(control.gcProcess)); } return result; } }
MiniAccumuloClusterImpl implements AccumuloCluster { public Map<ServerType,Collection<ProcessReference>> getProcesses() { Map<ServerType,Collection<ProcessReference>> result = new HashMap<>(); MiniAccumuloClusterControl control = getClusterControl(); result.put(ServerType.MANAGER, references(control.masterProcess)); result.put(ServerType.TABLET_SERVER, references(control.tabletServerProcesses.toArray(new Process[0]))); if (control.zooKeeperProcess != null) { result.put(ServerType.ZOOKEEPER, references(control.zooKeeperProcess)); } if (control.gcProcess != null) { result.put(ServerType.GARBAGE_COLLECTOR, references(control.gcProcess)); } return result; } MiniAccumuloClusterImpl(File dir, String rootPassword); @SuppressWarnings("deprecation")  MiniAccumuloClusterImpl(MiniAccumuloConfigImpl config); }
MiniAccumuloClusterImpl implements AccumuloCluster { public Map<ServerType,Collection<ProcessReference>> getProcesses() { Map<ServerType,Collection<ProcessReference>> result = new HashMap<>(); MiniAccumuloClusterControl control = getClusterControl(); result.put(ServerType.MANAGER, references(control.masterProcess)); result.put(ServerType.TABLET_SERVER, references(control.tabletServerProcesses.toArray(new Process[0]))); if (control.zooKeeperProcess != null) { result.put(ServerType.ZOOKEEPER, references(control.zooKeeperProcess)); } if (control.gcProcess != null) { result.put(ServerType.GARBAGE_COLLECTOR, references(control.gcProcess)); } return result; } MiniAccumuloClusterImpl(File dir, String rootPassword); @SuppressWarnings("deprecation")  MiniAccumuloClusterImpl(MiniAccumuloConfigImpl config); ProcessInfo exec(Class<?> clazz, String... args); ProcessInfo exec(Class<?> clazz, List<String> jvmArgs, String... args); ProcessInfo _exec(Class<?> clazz, ServerType serverType,
      Map<String,String> configOverrides, String... args); @SuppressFBWarnings(value = "UNENCRYPTED_SOCKET", justification = "insecure socket used for reservation") @Override synchronized void start(); Set<Pair<ServerType,Integer>> getDebugPorts(); Map<ServerType,Collection<ProcessReference>> getProcesses(); void killProcess(ServerType type, ProcessReference proc); @Override String getInstanceName(); @Override String getZooKeepers(); @Override synchronized ServerContext getServerContext(); @Override synchronized void stop(); MiniAccumuloConfigImpl getConfig(); @Override AccumuloClient createAccumuloClient(String user, AuthenticationToken token); @SuppressWarnings("deprecation") @Override org.apache.accumulo.core.client.ClientConfiguration getClientConfig(); @Override synchronized Properties getClientProperties(); @Override FileSystem getFileSystem(); MasterMonitorInfo getMasterMonitorInfo(); synchronized MiniDFSCluster getMiniDfs(); @Override MiniAccumuloClusterControl getClusterControl(); @Override Path getTemporaryPath(); @Override AccumuloConfiguration getSiteConfiguration(); @Override String getAccumuloPropertiesPath(); @Override String getClientPropsPath(); }
MiniAccumuloClusterImpl implements AccumuloCluster { public Map<ServerType,Collection<ProcessReference>> getProcesses() { Map<ServerType,Collection<ProcessReference>> result = new HashMap<>(); MiniAccumuloClusterControl control = getClusterControl(); result.put(ServerType.MANAGER, references(control.masterProcess)); result.put(ServerType.TABLET_SERVER, references(control.tabletServerProcesses.toArray(new Process[0]))); if (control.zooKeeperProcess != null) { result.put(ServerType.ZOOKEEPER, references(control.zooKeeperProcess)); } if (control.gcProcess != null) { result.put(ServerType.GARBAGE_COLLECTOR, references(control.gcProcess)); } return result; } MiniAccumuloClusterImpl(File dir, String rootPassword); @SuppressWarnings("deprecation")  MiniAccumuloClusterImpl(MiniAccumuloConfigImpl config); ProcessInfo exec(Class<?> clazz, String... args); ProcessInfo exec(Class<?> clazz, List<String> jvmArgs, String... args); ProcessInfo _exec(Class<?> clazz, ServerType serverType,
      Map<String,String> configOverrides, String... args); @SuppressFBWarnings(value = "UNENCRYPTED_SOCKET", justification = "insecure socket used for reservation") @Override synchronized void start(); Set<Pair<ServerType,Integer>> getDebugPorts(); Map<ServerType,Collection<ProcessReference>> getProcesses(); void killProcess(ServerType type, ProcessReference proc); @Override String getInstanceName(); @Override String getZooKeepers(); @Override synchronized ServerContext getServerContext(); @Override synchronized void stop(); MiniAccumuloConfigImpl getConfig(); @Override AccumuloClient createAccumuloClient(String user, AuthenticationToken token); @SuppressWarnings("deprecation") @Override org.apache.accumulo.core.client.ClientConfiguration getClientConfig(); @Override synchronized Properties getClientProperties(); @Override FileSystem getFileSystem(); MasterMonitorInfo getMasterMonitorInfo(); synchronized MiniDFSCluster getMiniDfs(); @Override MiniAccumuloClusterControl getClusterControl(); @Override Path getTemporaryPath(); @Override AccumuloConfiguration getSiteConfiguration(); @Override String getAccumuloPropertiesPath(); @Override String getClientPropsPath();  }