use of org.apache.accumulo.core.cli.ClientOnRequiredTable in project accumulo by apache.
the class RandomizeVolumes method main.
public static void main(String[] args) throws AccumuloException, AccumuloSecurityException {
ClientOnRequiredTable opts = new ClientOnRequiredTable();
opts.parseArgs(RandomizeVolumes.class.getName(), args);
Connector c;
if (opts.getToken() == null) {
Instance instance = opts.getInstance();
AccumuloServerContext context = new AccumuloServerContext(instance, new ServerConfigurationFactory(instance));
c = context.getConnector();
} else {
c = opts.getConnector();
}
try {
int status = randomize(c, opts.getTableName());
System.exit(status);
} catch (Exception ex) {
log.error("{}", ex.getMessage(), ex);
System.exit(4);
}
}
Aggregations