Diff stringlengths 10 2k | Message stringlengths 28 159 |
|---|---|
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not u... | Replace all tab characters in this file by sequences of white-spaces. |
package org.apache.accumulo.test; | Move the "org.apache.accumulo.test.randomwalk.unit.CreateTable" string literal on the left side of this string comparison. |
import org.apache.accumulo.core.security.thrift.Credentials;
synchronized public void fastHalt(TInfo tinfo, Credentials credentials, String lock) {
public TabletServerStatus getTabletServerStatus(TInfo tinfo, Credentials credentials) throws ThriftSecurityException, TException {
synchronized public void halt... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
private static final String checkboxIdSuffix = "_checkbox";
private static final String pageLoadFunctionName = "pageload";
sb.append("function ").append(pageLoadFunctionName).append("() {\n");
sb.append(" var checkboxes = document.getElementsByTagName('input');\n");
sb.append(" for (var i = 0; i < ch... | Rename this constant name to match the regular expression '^[A-Z][A-Z0-9]*(_[A-Z0-9]+)*$'. |
AccumuloOutputFormat.setOutputInfo(job.getConfiguration(), args[0], args[1].getBytes(), true, args[5]);
AccumuloOutputFormat.setZooKeeperInstance(job.getConfiguration(), args[3], args[4]); | 1 duplicated blocks of code must be removed. |
typeCheckValidFormat(PropertyType.ABSOLUTEPATH, "/foo", "/foo/c", "/");
// in hadoop 2.0 Path only normalizes Windows paths properly when run on a Windows system
// this makes the following checks fail
// typeCheckValidFormat(PropertyType.ABSOLUTEPATH, "d:\\foo12", "c:\\foo\\g", "c:\\foo\\c", "c:\\... | Remove this unused private "appendProp" method. |
log.trace(String.format("Splitting at %6.2f instead of .5, row at .5 is same as end row%n", keys.firstKey())); | Use isEmpty() to check whether the collection is empty or not. |
* Assign tablets to tablet servers. This method is called whenever the master finds tablets that are unassigned.
* @param assignments
* @param tableId
* @return A list of TabletMigration object that passed sanity checks. | Either log or rethrow this exception. |
private ReloadingClassLoader parent;
ContextManager(FileSystemManager vfs, ReloadingClassLoader parent) {
return loader.getClassLoader(); | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
/**
* @deprecated since 1.4
*/ | 6 duplicated blocks of code must be removed. |
import org.apache.accumulo.core.security.thrift.ThriftSecurityException; | 1 duplicated blocks of code must be removed. |
if (fs.getUsed() != 0)
tableRow(sb, (highlight = !highlight), "% of Used DFS", consumed); | Either log or rethrow this exception. |
public Process exec(Class<? extends Object> clazz, String... args) throws IOException {
appendProp(fileWriter, Property.TRACE_LOGIN_PROPERTIES + ".password", config.getRootPassword(), siteConfig);
appendProp(fileWriter, Property.TRACE_PORT, "" + getRandomFreePort(), siteConfig); | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
import static org.apache.accumulo.core.security.ColumnVisibility.quote;
import static org.junit.Assert.assertEquals;
import org.apache.accumulo.core.util.BadArgumentException;
} catch (BadArgumentException e) {
} catch (BadArgumentException e) {
} catch (BadArgumentException e) {
@Test
public v... | Reduce this switch case number of lines from 19 to at most 5, for example by extracting code into methods. |
import org.apache.accumulo.core.util.MetadataTable;
Scanner scanner = conn.createScanner(MetadataTable.NAME, opts.auths);
scanner.fetchColumnFamily(MetadataTable.DATAFILE_COLUMN_FAMILY); | Use "Long.toString" instead. |
import org.apache.accumulo.cloudtrace.instrument.Span;
import org.apache.accumulo.cloudtrace.instrument.Trace;
import org.apache.accumulo.cloudtrace.instrument.Tracer;
import org.apache.accumulo.cloudtrace.instrument.receivers.ZooSpanClient; | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
log.debug("Cloning table " + srcTableName + " " + newTableName + " " + flush); | Either log or rethrow this exception. |
import org.apache.thrift.transport.TTransport;
public TabletServerStatus getTableMap(boolean usePooledConnection) throws TException, ThriftSecurityException {
if (usePooledConnection == true)
throw new UnsupportedOperationException();
TTransport transport = ThriftUtil.createTranspo... | Remove the literal "true" boolean value. |
@Test(timeout = 3 * 60 * 1000)
Process ingest = cluster.exec(TestIngest.class, "-i", cluster.getInstanceName(), "-z", cluster.getZooKeepers(), "-u", "root", "-p", ROOT_PASSWORD, "--createTable");
@Test(timeout = 2 * 60 * 1000)
assertEquals(0, cluster.exec(TestIngest.class, "-i", cluster.getInstanceName(), "... | Either log or rethrow this exception. |
ZooKeeperInstance instance = new ZooKeeperInstance(accumulo.getConfig().getInstanceName(), accumulo.getConfig().getZooKeepers()); | Either log or rethrow this exception. |
* Autogenerated by Thrift Compiler (0.9.0)
import org.apache.thrift.protocol.TProtocolException;
import org.apache.thrift.EncodingUtils;
import org.apache.thrift.TException;
// check for sub-struct validity | Rename this class name to match the regular expression '^[A-Z][a-zA-Z0-9]*$'. |
import org.apache.accumulo.core.security.Credentials;
public TabletLocations lookupTablet(Credentials credentials, TabletLocation src, Text row, Text stopRow, TabletLocator parent)
boolean more = ThriftScanner.getBatchFromServer(instance, credentials, range, src.tablet_extent, src.tablet_location, encodedResult... | Immediately return this expression instead of assigning it to the temporary variable "onlineTabletsForTable". |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may ... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
/**
* @deprecated since 1.4
* @use org.apache.accumulo.core.iterators.user.SummingCombiner with SummingCombiner.Type.LONG
*/ | Either log or rethrow this exception. |
package org.apache.accumulo.test.randomwalk.shard;
import org.apache.accumulo.test.randomwalk.State;
import org.apache.accumulo.test.randomwalk.Test; | Move the "org.apache.accumulo.test.randomwalk.unit.CreateTable" string literal on the left side of this string comparison. |
if (bytes > 0 && Integer.parseInt(setting) > 10) {
log.warn("System swappiness setting is greater than ten (" + setting + ") which can cause time-sensitive operations to be delayed. " | Refactor this code to not nest more than 3 if/for/while/switch/try statements. |
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
/**
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may... | Rename this generic name to match the regular expression '^[A-Z]$'. |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not u... | Replace all tab characters in this file by sequences of white-spaces. |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not u... | Replace all tab characters in this file by sequences of white-spaces. |
import org.apache.accumulo.core.client.security.tokens.AuthenticationToken; | Move this constructor to comply with Java Code Conventions. |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not u... | Replace all tab characters in this file by sequences of white-spaces. |
import org.apache.accumulo.core.client.MutationsRejectedException;
try {
mtbw.close();
} catch (MutationsRejectedException e) {
throw new RuntimeException(e);
} | Define and throw a dedicated exception instead of using a generic one. |
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
* Autogenerated by Thrift Compiler (0.9.0)
import org.apache.thrift.protocol.TProtocolException;
import org.apache.thrift.EncodingUtils;
import org.apache.thrift.TException;
// check for sub-struct validity | Rename this class name to match the regular expression '^[A-Z][a-zA-Z0-9]*$'. |
/**
* @deprecated since 1.4
* @param conf
* @param fs
* @param dirName
* @return
*/
@SuppressWarnings("deprecation")
@SuppressWarnings("deprecation")
/**
* @deprecated sicne 1.4
*
* @param acuTableConf
* @param conf
* @param fs
* @param dirname
* @return
* @throws IOEx... | 6 duplicated blocks of code must be removed. |
* @since 1.5.0 | Move this constructor to comply with Java Code Conventions. |
import org.apache.accumulo.core.security.thrift.TCredentials;
private TCredentials credentials;
public TableOperationsImpl(Instance instance, TCredentials credentials) { | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not u... | Replace all tab characters in this file by sequences of white-spaces. |
package org.apache.accumulo.fate.zookeeper;
import org.apache.accumulo.fate.zookeeper.ZooReaderWriter.Mutator;
import org.apache.accumulo.fate.zookeeper.ZooUtil.NodeExistsPolicy;
import org.apache.accumulo.fate.zookeeper.ZooUtil.NodeMissingPolicy; | Remove this call to "exit" or ensure it is really required. |
zoo.putPersistentData(zTablePath + Constants.ZTABLE_NAME, tableName.getBytes(), existsPolicy);
zoo.putPersistentData(zTablePath + Constants.ZTABLE_STATE, state.name().getBytes(), existsPolicy);
zoo.putPersistentData(zTablePath + Constants.ZTABLE_FLUSH_ID, "0".getBytes(), existsPolicy);
zoo.putPersistent... | Remove this unused method parameter "ex". |
@Deprecated
@Deprecated | 3 duplicated blocks of code must be removed. |
import org.apache.accumulo.core.client.security.tokens.AuthenticationToken; | 1 duplicated blocks of code must be removed. |
* @deprecated since 1.4, replaced by {@link org.apache.accumulo.core.iterators.user.AgeOffFilter} | Either log or rethrow this exception. |
Collection<Text> splits = conn.tableOperations().listSplits(tableName, maxSplits); | Either log or rethrow this exception. |
import org.apache.accumulo.core.security.tokens.InstanceTokenWrapper;
private InstanceTokenWrapper credentials;
public TabletServerBatchDeleter(Instance instance, InstanceTokenWrapper credentials, String tableId, Authorizations authorizations, int numQueryThreads, | Immediately return this expression instead of assigning it to the temporary variable "ret". |
IDLE, RUNNING, QUEUED | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not u... | Replace all tab characters in this file by sequences of white-spaces. |
private final Callable<V> impl;
private final Span parent;
TraceCallable(Callable<V> impl) {
this(Trace.currentTrace(), impl);
}
TraceCallable(Span parent, Callable<V> impl) {
this.impl = impl;
this.parent = parent;
}
@Override
public V call() throws Exception {
if (parent != nu... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
private final TabletTime tabletTime;
private final Object timeLock = new Object();
public final Object bulkFileImportLock = new Object();
private final ReentrantLock logLock = new ReentrantLock(); | Move this variable to comply with Java Code Conventions. |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may ... | Make the "log" logger private static final and rename it to comply with the format "LOG(?:GER)?". |
import static org.apache.accumulo.fate.zookeeper.ZooUtil.NodeMissingPolicy.SKIP; | Remove this call to "exit" or ensure it is really required. |
if (pkey == null)
return null; | Return empty string instead. |
if (!shellState.getConnector().tableOperations().exists(tableName))
throw new TableNotFoundException(null, tableName, null);
if (sa.length < 2)
throw new IllegalArgumentException("Missing '='"); | Remove this call to "exit" or ensure it is really required. |
import org.apache.accumulo.core.security.Credentials;
public TabletLocation locateTablet(Credentials credentials, Text row, boolean skipRow, boolean retry) throws AccumuloException, AccumuloSecurityException,
TableNotFoundException {
public <T extends Mutation> void binMutations(Credentials credentials, List<... | Immediately return this expression instead of assigning it to the temporary variable "onlineTabletsForTable". |
if (everythingLooksGood)
System.out.println("All is well for table " + tablename);
else
sawProblems = true;
if (sawProblems)
System.exit(-1); | Remove this call to "exit" or ensure it is really required. |
import org.apache.accumulo.cloudtrace.instrument.Tracer;
return client.beginTableOperation(Tracer.traceInfo(), credentials);
client.executeTableOperation(Tracer.traceInfo(), credentials, opid, op, args, opts, autoCleanUp);
return client.waitForTableOperation(Tracer.traceInfo(), credentials, opid... | Immediately return this expression instead of assigning it to the temporary variable "client". |
package org.apache.accumulo.server.test.randomwalk.multitable;
import java.net.InetAddress;
import java.util.ArrayList;
import org.apache.accumulo.core.client.Connector;
import org.apache.accumulo.core.client.TableNotFoundException;
import org.apache.accumulo.server.test.randomwalk.Fixture;
import org.apache.accumulo... | Return empty string instead. |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may ... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
if (rootWriter != null) {
try {
rootWriter.close();
} catch (MutationsRejectedException e) {
log.error("Problem removing entries from the metadata table: ", e);
}
} | 1 duplicated blocks of code must be removed. |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not u... | Replace all tab characters in this file by sequences of white-spaces. |
import org.apache.accumulo.core.util.MetadataTable;
import org.apache.accumulo.core.util.RootTable;
@Parameter(names = "-update", description = "Make changes to the " + MetadataTable.NAME + " table to include missing files")
* A utility to add files to the {@value MetadataTable#NAME} table that are not listed in... | Use "Long.toString" instead. |
// Not really deprecated, just discouraging client use. | Define a constant instead of duplicating this literal "org.apache.accumulo.core.iterators.WholeRowIterator" 4 times. |
@Test(timeout=30*1000) | Either log or rethrow this exception. |
log.info("Zookeeper error, will retry", e); | Reorder the modifiers to comply with the Java Language Specification. |
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
import org.apache.accumulo.core.metadata.MetadataTable;
import org.apache.accumulo.core.metadata.schema.MetadataSchema;
Map<String,String> settings = new HashMap<String,String>();
@Test(timeout = 60 * 1000)
UtilWaitThread.sleep(5 * 1000);
@Test(timeout = 60 * 1000)
UtilWaitThread.sleep(10 * 1000);
... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
import org.apache.accumulo.core.metadata.RootTable;
import org.apache.accumulo.server.util.MetadataTableUtil;
MetadataTableUtil.LogEntry logEntry = new MetadataTableUtil.LogEntry(); | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
return address; | Remove this unused method parameter "threadName". |
import org.apache.accumulo.core.security.thrift.ThriftSecurityException;
import org.apache.accumulo.core.security.tokens.InstanceTokenWrapper;
public void initializeSecurity(InstanceTokenWrapper credentials, String rootuser) throws AccumuloSecurityException, ThriftSecurityException; | Immediately return this expression instead of assigning it to the temporary variable "ret". |
import org.apache.accumulo.core.security.Authorizations;
Scanner scanner = getConnector().createScanner("bwlt", Authorizations.EMPTY);
Scanner scanner = getConnector().createScanner("bwft", Authorizations.EMPTY); | Remove this unused method parameter "range". |
@Override
public int execute(String fullCommand, CommandLine cl, Shell shellState) throws AccumuloException, AccumuloSecurityException, TableNotFoundException,
TableExistsException {
shellState.getConnector().tableOperations().rename(cl.getArgs()[0], cl.getArgs()[1]);
if (shellState.getTableName().equ... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
public static class TColumnTranslator extends Translator<TColumn,Column> {
@Override
public Column translate(TColumn input) {
return new Column(input);
}
} | Remove this unused method parameter "range". |
import org.apache.accumulo.core.util.shell.Token;
throw new BadArgumentException("Property cannot be modified in zookeeper", fullCommand, fullCommand.indexOf(property)); | Remove the literal "true" boolean value. |
* @return The results of a query | 1 duplicated blocks of code must be removed. |
String _val47; // required
String _val53; // required | Rename this package name to match the regular expression '^[a-z]+(\.[a-z][a-z0-9]*)*$'. |
org.apache.accumulo.core.data.thrift.TConstraintViolationSummary _elem2; // optional
org.apache.accumulo.core.data.thrift.TConstraintViolationSummary _elem7; // optional | 277 duplicated blocks of code must be removed. |
zoo.recursiveDelete(ZooUtil.getRoot(instance) + "/loggers", NodeMissingPolicy.SKIP);
zoo.recursiveDelete(ZooUtil.getRoot(instance) + "/dead/loggers", NodeMissingPolicy.SKIP);
| 1 duplicated blocks of code must be removed. |
/**
* @param prevExtent
*/
public boolean isPreviousExtent(KeyExtent prevExtent) {
if (prevExtent == null)
return getPrevEndRow() == null;
if (!prevExtent.getTableId().equals(getTableId()))
throw new IllegalArgumentException("Cannot compare accross tables " + prevExtent + " " + thi... | Reduce the total number of break and continue statements in this loop to use at most one. |
@SuppressWarnings("all") public enum _Fields implements org.apache.thrift.TFieldIdEnum { | 300 duplicated blocks of code must be removed. |
import java.util.LinkedList;
import java.util.List;
import java.util.Set;
import java.util.TreeSet;
@Override
public List<Set<AuthProperty>> getProperties() {
List<Set<AuthProperty>> toRet = new LinkedList<Set<AuthProperty>>();
Set<AuthProperty> internal = new TreeSet<AuthProperty>();
internal.add(new ... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
String logConfig = String.format("%s/%s_logger.xml", System.getenv("ACCUMULO_CONF_DIR"), application);
logConfig = String.format("%s/generic_logger.xml", System.getenv("ACCUMULO_CONF_DIR")); | Remove the literal "false" boolean value. |
private Option mincScopeOpt, majcScopeOpt, scanScopeOpt, nameOpt;
public int execute(String fullCommand, CommandLine cl, Shell shellState) throws Exception {
String tableName = OptUtil.configureTableOpt(cl, shellState);
o.addOption(OptUtil.tableOpt("table to delete the iterator from")); | Reduce this switch case number of lines from 8 to at most 5, for example by extracting code into methods. |
public boolean hasTop() {
throw new NullPointerException();
}
@Override | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may ... | Remove the literal "true" boolean value. |
private final Instance instance;
MockConnector(String username, Instance instance) {
this(username, new MockAccumulo(), instance);
MockConnector(String username, MockAccumulo acu, Instance instance) {
this.instance = instance;
return instance; | Return empty string instead. |
import java.util.List;
import org.apache.accumulo.core.client.IteratorSetting;
public Map<String,List<IteratorSetting>> scanIteratorOptions = new HashMap<String,List<IteratorSetting>>();
for (Entry<String,List<IteratorSetting>> entry : scanIteratorOptions.entrySet()) {
for (IteratorSetting setting : ent... | Remove the literal "true" boolean value. |
import org.apache.accumulo.core.cli.ClientOnRequiredTable;
import com.beust.jcommander.Parameter;
static class Opts extends ClientOnRequiredTable {
@Parameter(names="--output", description="output directory")
String output;
@Parameter(names="--reducers", description="number of reducers to use", required=... | Remove this call to "exit" or ensure it is really required. |
package org.apache.accumulo.test.randomwalk.concurrent;
import org.apache.accumulo.test.randomwalk.State;
import org.apache.accumulo.test.randomwalk.Test; | Move the "org.apache.accumulo.test.randomwalk.unit.CreateTable" string literal on the left side of this string comparison. |
import java.util.Collections;
import java.util.Properties;
import java.util.Set;
@Override
public void init(Properties properties) {}
@Override
public Set<TokenProperty> getProperties() {
return Collections.emptySet();
} | Remove the redundant '!unknownSymbol!' thrown exception declaration(s). |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not u... | Replace all tab characters in this file by sequences of white-spaces. |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not u... | Replace all tab characters in this file by sequences of white-spaces. |
if (objectsCol.contains(lookupCol))
return true; | Remove this call to "exit" or ensure it is really required. |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not u... | Replace all tab characters in this file by sequences of white-spaces. |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may not u... | Replace all tab characters in this file by sequences of white-spaces. |
/*
* Licensed to the Apache Software Foundation (ASF) under one or more
* contributor license agreements. See the NOTICE file distributed with
* this work for additional information regarding copyright ownership.
* The ASF licenses this file to You under the Apache License, Version 2.0
* (the "License"); you may ... | Remove this unused private "appendProp" method. |
* Scans a table over a given range.
* This setting determines how long a scanner will automatically retry when a failure occurs. By default a scanner will retry forever.
* Returns the setting for how long a scanner will automatically retry when a failure occurs.
*
* Sets the range of keys to scan over.
... | Complete the task associated to this TODO comment. |
import org.apache.accumulo.proxy.thrift.UserPass;
protected static ByteBuffer userpass;
userpass = tpc.proxy().login(new UserPass("root", ByteBuffer.wrap("".getBytes())));
tpc.proxy().changeUserPassword(userpass, testuser, ByteBuffer.wrap("newpass".getBytes())); | Immediately return this expression instead of assigning it to the temporary variable "connector". |
import java.io.UnsupportedEncodingException;
import java.nio.charset.Charset;
import org.apache.commons.codec.binary.Base64;
public static final String HEADER = "!AUTH1:";
authsList.add(bs.toArray());
/**
* @param authorizations
* a serialized authorizations string produced by {@link #getAutho... | Move this constructor to comply with Java Code Conventions. |
import static org.junit.Assert.*;
assertEquals(1, groups.size());
assertNotNull(groups.get("lg1"));
assertEquals(2, groups.get("lg1").size());
assertTrue(groups.get("lg1").contains(new ArrayByteSequence("cf1")));
fail();
fail();
assertEquals(bs1, bs2);
assertEquals(ecf, Local... | Remove this unused private "appendProp" method. |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.