Diff stringlengths 10 2k | Message stringlengths 28 159 |
|---|---|
protected static ByteBuffer userpass;
userpass = tpc.proxy.login(new UserPass("root", ByteBuffer.wrap("".getBytes()))); | Replace this use of System.out or System.err by a logger. |
package org.apache.accumulo.test; | Move the "org.apache.accumulo.test.randomwalk.unit.CreateTable" string literal on the left side of this string comparison. |
if (node.name.equals(name))
return node;
if (depth == path.length)
return root;
if (child == null)
return null;
if (node == null)
return Collections.emptyList();
if (path.length == index)
return root;
if (parent == null)
return;
... | 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... | Immediately return this expression instead of assigning it to the temporary variable "r". |
import org.apache.accumulo.core.data.PartialKey;
if (!exists(tableName))
throw new TableNotFoundException(tableName, tableName, "");
acu.tables.get(tableName).setLocalityGroups(groups);
if (!exists(tableName))
throw new TableNotFoundException(tableName, tableName, "");
return acu.tables.get(... | Use "Integer.toString" instead. |
String file = key.getColumnQualifier().toString();
if (!file.startsWith("/"))
file = "/" + file;
Path map = new Path(ServerConstants.getTablesDir() + "/" + table + file); | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
/**
* Internal class used to verify validity of data read.
*/
/**
* Simple example for reading random batches of data from Accumulo. See docs/examples/README.batch for instructions.
*/
/**
* Generate a number of ranges, each covering a single random row.
*
* @param num
* the number of ranges... | Replace this use of System.out or System.err by a logger. |
return new MockInstanceOperations(acu); | Either log or rethrow this exception. |
/*
* 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. |
// TODO: Should we change this to an ArrayList so that we can just add() ? - ACCUMULO-1309
// TODO: Do I need to call new here? or can I just re-use the term? - ACCUMULO-1309 | Make the "log" logger private static final and rename it to comply with the format "LOG(?:GER)?". |
@Override
public int execute(final String fullCommand, final CommandLine cl, final Shell shellState) throws AccumuloException, AccumuloSecurityException,
TableNotFoundException, IOException, ConstraintViolationException {
new BatchWriterConfig().setMaxMemory(Math.max(m.estimatedMemoryUsed(), 1024))... | Return empty string instead. |
import org.apache.accumulo.core.iterators.SortedKeyValueIterator; | Replace all tab characters in this file by sequences of white-spaces. |
}
private void addOptions(StringBuilder sb, StatType selectedStatType) {
for (StatType st : StatType.values()) {
sb.append("<option").append(st.equals(selectedStatType) ? " selected='true'>" : ">").append(st.getDescription()).append("</option>");
}
}
private void doScript(StringBuilder sb, A... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
import java.util.TreeMap; | 2 duplicated blocks of code must be removed. |
package org.apache.accumulo.test.functional; | Move the "org.apache.accumulo.test.randomwalk.unit.CreateTable" string literal on the left side of this string comparison. |
for (String key : IteratorUtil.generateInitialTableProperties().keySet()) | Remove this unused private "match" method. |
public Repo<Master> call(long tid, Master master) throws Exception {
String path = ZooUtil.getRoot(master.getInstance()) + Constants.ZTSERVERS + "/" + tserver;
path = ZooUtil.getRoot(master.getInstance()) + Constants.ZDEADTSERVERS + "/" + tserver;
zoo.putPersistentData(path, "forced down".getBytes()... | Remove this unused private "appendProp" method. |
*
*
*
*
*
* | Replace all tab characters in this file by sequences of white-spaces. |
@SuppressWarnings("all") public enum _Fields implements org.apache.thrift.TFieldIdEnum { | 300 duplicated blocks of code must be removed. |
import static org.junit.Assert.assertArrayEquals;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertFalse;
import static org.junit.Assert.assertNull;
import static org.junit.Assert.assertTrue;
BatchWriterOpts bwOpts = new BatchWriterOpts();
BatchScannerOpts bsOpts = new BatchScan... | Remove this unused method parameter "opts". |
package org.apache.accumulo.core.security;
import java.io.Serializable;
import org.apache.accumulo.core.security.Authorizations;
import org.apache.accumulo.core.security.ColumnVisibility;
public interface VisibilityInterpreter extends Serializable
{
public abstract String getAbbreviatedValue ();
public... | Return empty string instead. |
System.out.printf("mapType:%10s put rate:%,6.2f scan rate:%,6.2f get rate:%,6.2f delete time : %6.2f mem : %,d%n", "" + mapType, (numRows * numCols) | Use isEmpty() to check whether the collection is empty or not. |
/**
* Generate the initial (default) properties for a table
* @param limitVersion
* include a VersioningIterator at priority 20 that retains a single version of a given K/V pair.
* @return A map of Table properties
*/
public static Map<String,String> generateInitialTableProperties(boolean limitVers... | Either log or rethrow this exception. |
* 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.cli.BatchWriterOpts;
import org.apache.accumulo.core.cli.ClientOpts;
import org.apache.accumulo.core.cli.ScannerOpts;
import com.beust.jcommander.Parameter;
static class Opts extends ClientOpts {
@Parameter(names="--shardTable")
String shardTable = "shard";
@Parameter(n... | Remove this unused private "appendProp" method. |
ROW(1), ROW_COLFAM(2), ROW_COLFAM_COLQUAL(3), ROW_COLFAM_COLQUAL_COLVIS(4), ROW_COLFAM_COLQUAL_COLVIS_TIME(5), ROW_COLFAM_COLQUAL_COLVIS_TIME_DEL(6) // everything
// w... | 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 local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
/**
* @deprecated since 1.4
*/
/**
* @deprecated since 1.4
*/ | 6 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. |
package org.apache.accumulo.examples.wikisearch.iterator; | 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. |
import java.nio.charset.Charset;
private static final Charset utf8 = Charset.forName("UTF8");
zk.putPersistentData(path, (reservationID + ":" + debugInfo).getBytes(utf8), NodeExistsPolicy.FAIL); | 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 not u... | Replace all tab characters in this file by sequences of white-spaces. |
currentRow = new Text();
currentDocID.set(emptyByteArray);
doSeek(range, seekColumnFamilies, inclusive);
}
private void doSeek(Range range, Collection<ByteSequence> seekColumnFamilies, boolean inclusive) throws IOException {
log.debug("doSeek, topKey is outside of overall range: " + overa... | 31 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. |
} catch (TException e) {
throw new IOException(e); | Rename this class name to match the regular expression '^[A-Z][a-zA-Z0-9]*$'. |
public class CachedBlock implements HeapSize, Comparable<CachedBlock>, CacheEntry {
private Object index;
@Override
@Override
public Object getIndex() {
return index;
}
@Override
public void setIndex(Object idx) {
this.index = idx;
} | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
import java.util.ArrayList;
import java.util.List;
import org.apache.accumulo.core.cli.Help;
import com.beust.jcommander.JCommander;
import com.beust.jcommander.Parameter;
import com.beust.jcommander.Parameters;
static class TxOpts {
@Parameter(description="<txid>", required=true)
List<String> args = ne... | Remove this unused private "appendProp" method. |
if (startRow == null && endRow == null) {
shellState.getReader().flushConsole();
String line = shellState.getReader().readLine("Merge the entire table { " + tableName + " } into one tablet (yes|no)? ");
if (line == null)
return 0;
if (!line.equalsIgnoreCase("y") && !line.equalsIgnore... | Move the "y" string literal on the left side of this string comparison. |
import org.apache.commons.cli.CommandLine;
import org.apache.commons.cli.Option;
import org.apache.commons.cli.Options;
private boolean wait;
private Option waitOpt;
shellState.getConnector().tableOperations().offline(tableName, wait);
Shell.log.info("Offline of table " + tableName + (wait ? " com... | Cast one of the operands of this multiplication operation to a "long". |
import org.apache.accumulo.core.security.tokens.SecurityToken;
public static synchronized TabletLocator getInstance(Instance instance, SecurityToken credentials, Text tableId) { | Either log or rethrow this exception. |
import org.apache.accumulo.core.security.tokens.AccumuloToken;
import org.apache.hadoop.fs.Path;
* <li>{@link AccumuloInputFormat#setConnectorInfo(Job, AccumuloToken)} OR {@link AccumuloInputFormat#setConnectorInfo(Job, Path)} | Define and throw a dedicated exception instead of using a generic one. |
shellState.getConnector().securityOperations().dropLocalUser(user); | 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. |
package org.apache.accumulo.server.test.randomwalk.concurrent;
import java.util.List;
import java.util.Map.Entry;
import java.util.Properties;
import java.util.Random;
import org.apache.accumulo.core.Constants;
import org.apache.accumulo.core.client.Connector;
import org.apache.accumulo.core.client.IsolatedScanner;
i... | 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 not u... | Replace all tab characters in this file by sequences of white-spaces. |
import org.apache.accumulo.fate.zookeeper.ZooReader; | Remove this call to "exit" or ensure it is really required. |
package org.apache.accumulo.examples.simple.isolation; | Rename "table" which hides the field declared at line 107. |
import java.nio.charset.Charset;
private static final Charset utf8 = Charset.forName("UTF8");
store.put(Constants.ZROOT_TABLET_FUTURE_LOCATION, value.getBytes(utf8));
store.put(Constants.ZROOT_TABLET_LOCATION, value.getBytes(utf8));
store.put(Constants.ZROOT_TABLET_LAST_LOCATION, value.getBytes(utf8)); | Move this variable to comply with Java Code Conventions. |
import org.apache.accumulo.proxy.thrift.WriterOptions;
int threads = 10;
if (opts != null && opts.threads > 0)
threads = opts.threads;
BatchScanner scanner = connector.createBatchScanner(tableName, auth, threads);
BatchWriter writer = getWriter(userpass, tableName, null);
public String... | Remove this unused import 'java.util.Arrays'. |
assertEquals(0, exec(CacheTestWriter.class, "/zcTest-42", "/tmp/zcTest-42", "3","50").waitFor()); | Either log or rethrow this exception. |
/*
* 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. |
return "Server Activity";
else if (size.equals("80"))
spacing = 80;
.append(spacing == 40 ? " selected='true'" : "").append(">40</option><option").append(spacing == 80 ? " selected='true'" : "")
.append(">80</option></select></span>\n"); | Move the "80" string literal on the left side of this string comparison. |
/*
* 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. |
return authString == null ? Constants.NO_AUTHS : new Authorizations(authString.getBytes()); | Move this constructor to comply with Java Code Conventions. |
getConnector().securityOperations().createUser(TEST_USER, TEST_PASS.getBytes());
test_user_conn.securityOperations().createUser(user, password.getBytes());
root_conn.securityOperations().createUser(user, password.getBytes());
root_conn.securityOperations().createUser(user, password... | Remove the redundant '!unknownSymbol!' thrown exception declaration(s). |
Connector conn = master.getConnector();
String tableDir = Constants.getMetadataTableDir(master.getConfiguration().getConfiguration());
public Repo<Master> call(long tid, Master master) throws Exception {
MergeInfo mergeInfo = master.getMergeInfo(tableIdText);
master.clearMergeState(tableIdText); | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
import org.apache.accumulo.server.util.MetadataTable;
for (String cq : MetadataTable.getDataFileSizes(ke, token).keySet()) {
files.add(ServerConstants.getTablesDir() + "/" + tableId + cq); | Either log or rethrow this exception. |
package org.apache.accumulo.examples.aggregation;
import java.util.TreeSet;
import org.apache.accumulo.core.data.Value;
import org.apache.accumulo.core.iterators.aggregation.Aggregator;
import org.apache.accumulo.core.util.StringUtil;
public class SortedSetAggregator implements Aggregator
{
TreeSet<String> items ... | Return empty string instead. |
import jline.console.ConsoleReader;
reader.println(itopts.getDescription());
reader.flush();
reader.println();
reader.println(Shell.repeat("-", 10) + "> entering options: " + desc);
reader.flush();
reader.println();
reader.println("invalid options ... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
void span(long traceId, long spanId, long parentId, long start, long stop, String description, Map<String,String> data);
void flush(); | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
if (parts[1].isEmpty())
return new InetSocketAddress(parts[0], defaultPort); | Remove this call to "exit" or ensure it is really required. |
private static VisibilityInterpreter interpreter = null;
public static VisibilityInterpreter create() {
if (interpreter == null) {
throw new IllegalStateException("ColumnVisibilityInterpreterFactory is not configured: Interpreter is null");
return interpreter.create();
}
public static Visib... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
AccumuloInputFormat.setConnectorInfo(job, user, new PasswordToken(pass)); | 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... | 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 this hard-coded password. |
Map<String,Long> lowBulkFiles = MetadataTable.getBulkFilesLoaded(SecurityConstants.getSystemCredentials(), low);
Map<String,Long> highBulkFiles = MetadataTable.getBulkFilesLoaded(SecurityConstants.getSystemCredentials(), high);
if (!lowBulkFiles.equals(highBulkFiles)) {
throw new Exception("... | 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 u... | Replace all tab characters in this file by sequences of white-spaces. |
} else
assignments.put(mapFile, tabletsToAssignMapFileTo);
if (tabletsToAssignMapFileTo.size() > 0)
assignments.put(entry.getKey(), tabletsToAssignMapFileTo);
if (fc == null)
fc = 0;
if (entry.getValue().size() == 0)
afIter.remo... | Remove this call to "exit" or ensure it is really required. |
import org.apache.accumulo.core.client.BatchWriterConfig;
.createBatchWriter(Constants.METADATA_TABLE_NAME, new BatchWriterConfig()); | Remove this unused method parameter "e". |
String[] parts = extractPartsFromAddress(address);
static public InetSocketAddress parseAddress(String address) throws NumberFormatException {
String[] parts = extractPartsFromAddress(address);
if (parts.length == 2)
return new InetSocketAddress(parts[0], Integer.parseInt(parts[1]));
else
... | Immediately return this expression instead of assigning it to the temporary variable "client". |
public static String join(Collection<String> strings, String sep) {
int last = 0;
StringBuilder ret = new StringBuilder();
for (String s : strings) {
ret.append(s);
last = ret.length();
ret.append(sep);
ret.delete(last, ret.length());
return ret.toString();
} | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
public class DeleteEverythingIT extends ConfigurableMacIT { | Use "Integer.toString" instead. |
public class DynamicThreadPoolsIT extends ConfigurableMacIT {
TCredentials creds = CredentialHelper.create("root", new PasswordToken(ROOT_PASSWORD), c.getInstance().getInstanceName()); | Use "Integer.toString" instead. |
package org.apache.accumulo.core.util;
import junit.framework.TestCase;
import org.apache.accumulo.core.util.TextUtil;
import org.apache.hadoop.io.Text;
/**
* Test the TextUtil class.
*
*/
public class TextUtilTest extends TestCase {
/**
* co
*/
public void testGetBytes(){
String longMessage = "This is so... | Return empty string instead. |
final byte[] password = p.getBytes(); | Remove this unused method parameter "ex". |
/*
* 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 ... | 296 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... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
import org.apache.accumulo.trace.instrument.Tracer;
import org.apache.accumulo.trace.thrift.TInfo;
@Override
public void unableToMonitorLockNode(Throwable e) {
try {
tch.halt(Tracer.traceInfo(), null, null);
} catch (Exception ex) {
log.error(ex, ex);
Sys... | Remove this call to "exit" or ensure it is really required. |
private byte[] columnFamily;
private byte[] columnQualifier;
private byte[] columnVisibility;
private long timestamp;
private boolean hasTimestamp;
private byte[] val;
private byte[] data;
private int tsOffset;
private boolean deleted;
public ColumnUpdate(byte[] cf, byte[] cq, byte[] cv, boole... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
import org.apache.accumulo.core.util.FastFormat; | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
public HashMap<String, Object> getMap() {
return stateMap;
}
| Immediately return this expression instead of assigning it to the temporary variable "res". |
private static final int TSERV_MINC_MAXCONCURRENT_NUMWAITING_MULTIPLIER = 2;
@Override
numWaitingMultiplier = TSERV_MINC_MAXCONCURRENT_NUMWAITING_MULTIPLIER; | Use "Long.toString" instead. |
package normalizer;
import static org.junit.Assert.assertTrue;
import org.junit.Test;
public class testNumberNormalizer {
@Test
public void test1() throws Exception {
NumberNormalizer nn = new NumberNormalizer();
String n1 = nn.normalizeFieldValue(null, "1");
String n2 = nn.normalizeFieldValue(null, "1... | Return empty string instead. |
public enum PartialKey implements org.apache.thrift.TEnum {
private PartialKey(int value) {
public static PartialKey findByValue(int value) { | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
* @since 1.5.0 | Move this constructor to comply with Java Code Conventions. |
import org.apache.accumulo.core.security.Credentials;
public static boolean getBatchFromServer(Instance instance, Credentials credentials, Range range, KeyExtent extent, String server,
SortedMap<Key,Value> results, SortedSet<Column> fetchedColumns, List<IterInfo> serverSideIteratorList,
Map<String,Map<Str... | 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 not... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
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. |
System.out.printf(" %-" + NAME_WIDTH + "s| %-" + UUID_WIDTH + "s| %-" + MASTER_WIDTH + "s%n", "Instance Name", "Instance ID", "Master");
System.out.printf("%" + (NAME_WIDTH + 1) + "s+%" + (UUID_WIDTH + 1) + "s+%" + (MASTER_WIDTH + 1) + "s%n", new CharFiller('-'), new CharFiller('-'),
System.out.printf("%" +... | Use isEmpty() to check whether the collection is empty or not. |
package org.apache.accumulo.server.tabletserver;
public class CompactionStats {
private long entriesRead;
private long entriesWritten;
private long fileSize;
CompactionStats(long er, long ew){
this.setEntriesRead(er);
this.setEntriesWritten(ew);
}
public CompactionStats() {
}
private void setEntriesRead... | Return empty string instead. |
import org.apache.accumulo.cloudtrace.instrument.Trace; | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
throw new IllegalArgumentException("no type specified");
throw new IllegalArgumentException(); | Complete the task associated to this TODO comment. |
private static final Logger log = Logger.getLogger(DumpMapFile.class);
public static void main(String[] args) {
try {
Configuration conf = CachedConfiguration.getInstance();
FileSystem fs = FileSystem.get(conf);
MyMapFile.Reader mr = new MyMapFile.Reader(fs, args[0], conf);
Key... | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
* Gets the serialized token class from either the configuration or the token file.
* @deprecated since 1.6.0; Use {@link #getAuthenticationToken(JobConf)} instead.
@Deprecated
return getAuthenticationToken(job).getClass().getName();
* Gets the serialized token from either the configuration or the ... | This block of commented-out lines of code should be removed. |
package org.apache.accumulo.core.util.shell.commands;
import java.io.IOException;
import java.util.Map;
import java.util.Set;
import org.apache.accumulo.core.client.AccumuloException;
import org.apache.accumulo.core.client.AccumuloSecurityException;
import org.apache.accumulo.core.client.TableNotFoundException;
impor... | Return empty string instead. |
this(username, new MockAccumulo(MockInstance.getDefaultFileSystem()), instance); | Either log or rethrow this exception. |
import org.apache.accumulo.core.iterators.user.NoVisFilter;
import org.apache.accumulo.core.iterators.user.RegExFilter;
import org.apache.accumulo.core.iterators.user.VersioningIterator;
classname = RegExFilter.class.getName();
classname = NoVisFilter.class.getName(); | Remove this unused private "match" method. |
import org.apache.accumulo.core.security.thrift.Credential;
void send(Credential info, String serverName, MasterClientService.Iface client) throws TException, ThriftSecurityException; | Rename this local variable to match the regular expression '^[a-z][a-zA-Z0-9]*$'. |
import java.util.concurrent.TimeUnit;
import org.apache.accumulo.core.cli.BatchScannerOpts;
BatchScannerOpts bsOpts = new BatchScannerOpts();
opts.parseArgs(RandomBatchScanner.class.getName(), args, bsOpts);
BatchScanner batchReader = connector.createBatchScanner(opts.tableName, opts.auths, bsOpts.scanThrea... | Remove this unused method parameter "opts". |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.