From d4015f8628dd973c7433639451a9acc3e741d2a2 Mon Sep 17 00:00:00 2001 From: Akira Ajisaka Date: Tue, 30 May 2017 14:48:58 +0900 Subject: [PATCH] MAPREDUCE-6887. Modifier 'static' is redundant for inner enums. Contributed by ZhangBing Lin. --- .../mapreduce/v2/app/launcher/ContainerLauncherImpl.java | 2 +- .../main/java/org/apache/hadoop/mapreduce/v2/util/MRApps.java | 4 ++-- .../main/java/org/apache/hadoop/mapred/FileInputFormat.java | 2 +- .../main/java/org/apache/hadoop/mapred/FileOutputFormat.java | 2 +- .../src/main/java/org/apache/hadoop/mapred/JobClient.java | 2 +- .../src/main/java/org/apache/hadoop/mapred/JobInProgress.java | 2 +- .../src/main/java/org/apache/hadoop/mapred/JobTracker.java | 2 +- .../src/main/java/org/apache/hadoop/mapred/Task.java | 2 +- .../src/main/java/org/apache/hadoop/mapred/TaskLog.java | 2 +- .../src/main/java/org/apache/hadoop/mapred/TaskStatus.java | 4 ++-- .../java/org/apache/hadoop/mapred/pipes/BinaryProtocol.java | 2 +- .../src/main/java/org/apache/hadoop/mapreduce/Cluster.java | 2 +- .../src/main/java/org/apache/hadoop/mapreduce/Job.java | 4 ++-- .../src/main/java/org/apache/hadoop/mapreduce/JobStatus.java | 2 +- .../apache/hadoop/mapreduce/lib/input/FileInputFormat.java | 2 +- .../apache/hadoop/mapreduce/lib/jobcontrol/ControlledJob.java | 2 +- .../apache/hadoop/mapreduce/lib/jobcontrol/JobControl.java | 2 +- .../apache/hadoop/mapreduce/lib/output/FileOutputFormat.java | 2 +- .../java/org/apache/hadoop/mapreduce/task/reduce/Fetcher.java | 2 +- .../java/org/apache/hadoop/mapreduce/task/reduce/MapHost.java | 2 +- .../java/org/apache/hadoop/mapreduce/v2/hs/HSAuditLogger.java | 2 +- .../org/apache/hadoop/mapreduce/v2/hs/HistoryFileManager.java | 2 +- .../src/test/java/org/apache/hadoop/RandomTextWriterJob.java | 2 +- .../src/test/java/org/apache/hadoop/fs/JHLogAnalyzer.java | 2 +- .../src/test/java/org/apache/hadoop/fs/TestDFSIO.java | 4 ++-- .../test/java/org/apache/hadoop/fs/slive/OperationOutput.java | 2 +- .../src/test/java/org/apache/hadoop/fs/slive/PathFinder.java | 2 +- .../java/org/apache/hadoop/mapred/GenericMRLoadGenerator.java | 2 +- .../src/test/java/org/apache/hadoop/mapred/MRBench.java | 2 +- .../java/org/apache/hadoop/mapred/ThreadedMapBenchmark.java | 2 +- .../org/apache/hadoop/mapreduce/GenericMRLoadGenerator.java | 2 +- .../test/java/org/apache/hadoop/mapreduce/LargeSorter.java | 2 +- .../java/org/apache/hadoop/mapreduce/RandomTextWriter.java | 2 +- .../test/java/org/apache/hadoop/mapreduce/RandomWriter.java | 2 +- .../apache/hadoop/mapreduce/TimelineServicePerformance.java | 2 +- .../java/org/apache/hadoop/examples/RandomTextWriter.java | 2 +- .../main/java/org/apache/hadoop/examples/RandomWriter.java | 2 +- .../java/org/apache/hadoop/examples/terasort/TeraGen.java | 2 +- 38 files changed, 42 insertions(+), 42 deletions(-) diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-app/src/main/java/org/apache/hadoop/mapreduce/v2/app/launcher/ContainerLauncherImpl.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-app/src/main/java/org/apache/hadoop/mapreduce/v2/app/launcher/ContainerLauncherImpl.java index 58fd7b502f..cb4f0c92b3 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-app/src/main/java/org/apache/hadoop/mapreduce/v2/app/launcher/ContainerLauncherImpl.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-app/src/main/java/org/apache/hadoop/mapreduce/v2/app/launcher/ContainerLauncherImpl.java @@ -102,7 +102,7 @@ private void removeContainerIfDone(ContainerId id) { } } - private static enum ContainerState { + private enum ContainerState { PREP, FAILED, RUNNING, DONE, KILLED_BEFORE_LAUNCH } diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-common/src/main/java/org/apache/hadoop/mapreduce/v2/util/MRApps.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-common/src/main/java/org/apache/hadoop/mapreduce/v2/util/MRApps.java index b800d31eaa..5fd66acea3 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-common/src/main/java/org/apache/hadoop/mapreduce/v2/util/MRApps.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-common/src/main/java/org/apache/hadoop/mapreduce/v2/util/MRApps.java @@ -114,7 +114,7 @@ public static String taskSymbol(TaskType type) { throw new YarnRuntimeException("Unknown task type: "+ type.toString()); } - public static enum TaskAttemptStateUI { + public enum TaskAttemptStateUI { NEW( new TaskAttemptState[] { TaskAttemptState.NEW, TaskAttemptState.STARTING }), @@ -136,7 +136,7 @@ public boolean correspondsTo(TaskAttemptState state) { } } - public static enum TaskStateUI { + public enum TaskStateUI { RUNNING( new TaskState[]{TaskState.RUNNING}), PENDING(new TaskState[]{TaskState.SCHEDULED}), diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/FileInputFormat.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/FileInputFormat.java index 5803d60d02..3e0ea25333 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/FileInputFormat.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/FileInputFormat.java @@ -72,7 +72,7 @@ public abstract class FileInputFormat implements InputFormat { LogFactory.getLog(FileInputFormat.class); @Deprecated - public static enum Counter { + public enum Counter { BYTES_READ } diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/FileOutputFormat.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/FileOutputFormat.java index 821c1e8943..3932e5849e 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/FileOutputFormat.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/FileOutputFormat.java @@ -36,7 +36,7 @@ public abstract class FileOutputFormat implements OutputFormat { @Deprecated - public static enum Counter { + public enum Counter { BYTES_WRITTEN } diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobClient.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobClient.java index c43fc0a9a0..2f8dd63cce 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobClient.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobClient.java @@ -152,7 +152,7 @@ public class JobClient extends CLI implements AutoCloseable { public static final String MAPREDUCE_CLIENT_RETRY_POLICY_SPEC_DEFAULT = "10000,6,60000,10"; // t1,n1,t2,n2,... - public static enum TaskStatusFilter { NONE, KILLED, FAILED, SUCCEEDED, ALL } + public enum TaskStatusFilter { NONE, KILLED, FAILED, SUCCEEDED, ALL } private TaskStatusFilter taskOutputFilter = TaskStatusFilter.FAILED; private int maxRetry = MRJobConfig.DEFAULT_MR_CLIENT_JOB_MAX_RETRIES; diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobInProgress.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobInProgress.java index 1fd2eb3a5f..a899801585 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobInProgress.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobInProgress.java @@ -30,7 +30,7 @@ public class JobInProgress { * @deprecated Provided for compatibility. Use {@link JobCounter} instead. */ @Deprecated - public static enum Counter { + public enum Counter { NUM_FAILED_MAPS, NUM_FAILED_REDUCES, TOTAL_LAUNCHED_MAPS, diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobTracker.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobTracker.java index 7999500881..7cfdc02cc9 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobTracker.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobTracker.java @@ -28,7 +28,7 @@ public class JobTracker { * State is no longer used since M/R 2.x. It is kept in case * that M/R 1.x applications may still use it. */ - public static enum State { + public enum State { INITIALIZING, RUNNING } diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/Task.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/Task.java index c1ae0ab969..b0347fd320 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/Task.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/Task.java @@ -90,7 +90,7 @@ abstract public class Task implements Writable, Configurable { * @deprecated Provided for compatibility. Use {@link TaskCounter} instead. */ @Deprecated - public static enum Counter { + public enum Counter { MAP_INPUT_RECORDS, MAP_OUTPUT_RECORDS, MAP_SKIPPED_RECORDS, diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/TaskLog.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/TaskLog.java index bf838c2388..059b0ad31e 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/TaskLog.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/TaskLog.java @@ -358,7 +358,7 @@ public void run() { * The filter for userlogs. */ @InterfaceAudience.Private - public static enum LogName { + public enum LogName { /** Log on the stdout of the task. */ STDOUT ("stdout"), diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/TaskStatus.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/TaskStatus.java index a5c12de262..bd12cd34d7 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/TaskStatus.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/TaskStatus.java @@ -45,12 +45,12 @@ public abstract class TaskStatus implements Writable, Cloneable { //enumeration for reporting current phase of a task. @InterfaceAudience.Private @InterfaceStability.Unstable - public static enum Phase{STARTING, MAP, SHUFFLE, SORT, REDUCE, CLEANUP} + public enum Phase{STARTING, MAP, SHUFFLE, SORT, REDUCE, CLEANUP} // what state is the task in? @InterfaceAudience.Private @InterfaceStability.Unstable - public static enum State {RUNNING, SUCCEEDED, FAILED, UNASSIGNED, KILLED, + public enum State {RUNNING, SUCCEEDED, FAILED, UNASSIGNED, KILLED, COMMIT_PENDING, FAILED_UNCLEAN, KILLED_UNCLEAN, PREEMPTED} private final TaskAttemptID taskid; diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/pipes/BinaryProtocol.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/pipes/BinaryProtocol.java index 5a3ed5ba70..d19672329c 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/pipes/BinaryProtocol.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/pipes/BinaryProtocol.java @@ -68,7 +68,7 @@ class BinaryProtocol extends InputFormat { private static final double SPLIT_SLOP = 1.1; // 10% slop @Deprecated - public static enum Counter { + public enum Counter { BYTES_READ } diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/jobcontrol/ControlledJob.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/jobcontrol/ControlledJob.java index 4d5be68dc4..f2b47345b2 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/jobcontrol/ControlledJob.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/jobcontrol/ControlledJob.java @@ -52,7 +52,7 @@ public class ControlledJob { private static final Log LOG = LogFactory.getLog(ControlledJob.class); // A job will be in one of the following states - public static enum State {SUCCESS, WAITING, RUNNING, READY, FAILED, + public enum State {SUCCESS, WAITING, RUNNING, READY, FAILED, DEPENDENT_FAILED}; public static final String CREATE_DIR = "mapreduce.jobcontrol.createdir.ifnotexist"; private State state; diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/jobcontrol/JobControl.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/jobcontrol/JobControl.java index e5399b5f74..4c7114a4f2 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/jobcontrol/JobControl.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/jobcontrol/JobControl.java @@ -58,7 +58,7 @@ public class JobControl implements Runnable { private static final Log LOG = LogFactory.getLog(JobControl.class); // The thread can be in one of the following state - public static enum ThreadState {RUNNING, SUSPENDED,STOPPED, STOPPING, READY}; + public enum ThreadState {RUNNING, SUSPENDED,STOPPED, STOPPING, READY}; private ThreadState runnerState; // the thread state diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/output/FileOutputFormat.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/output/FileOutputFormat.java index 2c6954275f..c11f8d86d5 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/output/FileOutputFormat.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/output/FileOutputFormat.java @@ -61,7 +61,7 @@ public abstract class FileOutputFormat extends OutputFormat { public static final String OUTDIR = "mapreduce.output.fileoutputformat.outputdir"; @Deprecated - public static enum Counter { + public enum Counter { BYTES_WRITTEN } diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/task/reduce/Fetcher.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/task/reduce/Fetcher.java index c6889cb3bd..6112fb53f9 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/task/reduce/Fetcher.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/task/reduce/Fetcher.java @@ -71,7 +71,7 @@ class Fetcher extends Thread { private static final String FETCH_RETRY_AFTER_HEADER = "Retry-After"; protected final Reporter reporter; - private static enum ShuffleErrors{IO_ERROR, WRONG_LENGTH, BAD_ID, WRONG_MAP, + private enum ShuffleErrors{IO_ERROR, WRONG_LENGTH, BAD_ID, WRONG_MAP, CONNECTION, WRONG_REDUCE} private final static String SHUFFLE_ERR_GRP_NAME = "Shuffle Errors"; diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/task/reduce/MapHost.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/task/reduce/MapHost.java index dfb28de3c5..948e02aba0 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/task/reduce/MapHost.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/task/reduce/MapHost.java @@ -29,7 +29,7 @@ @InterfaceStability.Unstable public class MapHost { - public static enum State { + public enum State { IDLE, // No map outputs available BUSY, // Map outputs are being fetched PENDING, // Known map outputs which need to be fetched diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/HSAuditLogger.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/HSAuditLogger.java index f4deab0a86..5d851a5fd6 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/HSAuditLogger.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/HSAuditLogger.java @@ -29,7 +29,7 @@ public class HSAuditLogger { private static final Log LOG = LogFactory.getLog(HSAuditLogger.class); - static enum Keys { + enum Keys { USER, OPERATION, TARGET, RESULT, IP, PERMISSIONS, DESCRIPTION } diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/HistoryFileManager.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/HistoryFileManager.java index 6b98e47055..c7d6d19763 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/HistoryFileManager.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-hs/src/main/java/org/apache/hadoop/mapreduce/v2/hs/HistoryFileManager.java @@ -87,7 +87,7 @@ public class HistoryFileManager extends AbstractService { private static final Log LOG = LogFactory.getLog(HistoryFileManager.class); private static final Log SUMMARY_LOG = LogFactory.getLog(JobSummary.class); - private static enum HistoryInfoState { + private enum HistoryInfoState { IN_INTERMEDIATE, IN_DONE, DELETED, MOVE_FAILED }; diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/RandomTextWriterJob.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/RandomTextWriterJob.java index 2d341e9fda..1e3ee8c357 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/RandomTextWriterJob.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/RandomTextWriterJob.java @@ -53,7 +53,7 @@ public class RandomTextWriterJob extends Configured implements Tool { public static final String MIN_KEY = "mapreduce.randomtextwriter.minwordskey"; public static final String MAX_KEY = "mapreduce.randomtextwriter.maxwordskey"; - static enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } + enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } public Job createJob(Configuration conf) throws IOException { long numBytesToWritePerMap = conf.getLong(BYTES_PER_MAP, 10 * 1024); diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/JHLogAnalyzer.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/JHLogAnalyzer.java index 8b3f4c895e..91c3c2688c 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/JHLogAnalyzer.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/JHLogAnalyzer.java @@ -162,7 +162,7 @@ public class JHLogAnalyzer { Configuration.addDefaultResource("hdfs-site.xml"); } - static enum StatSeries { + enum StatSeries { STAT_ALL_SLOT_TIME (AccumulatingReducer.VALUE_TYPE_LONG + "allSlotTime"), STAT_FAILED_SLOT_TIME diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/TestDFSIO.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/TestDFSIO.java index 2eb4b29be7..34eac83ae5 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/TestDFSIO.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/TestDFSIO.java @@ -123,7 +123,7 @@ public class TestDFSIO implements Tool { Configuration.addDefaultResource("mapred-site.xml"); } - private static enum TestType { + private enum TestType { TEST_TYPE_READ("read"), TEST_TYPE_WRITE("write"), TEST_TYPE_CLEANUP("cleanup"), @@ -145,7 +145,7 @@ public String toString() { } } - static enum ByteMultiple { + enum ByteMultiple { B(1L), KB(0x400L), MB(0x100000L), diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/slive/OperationOutput.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/slive/OperationOutput.java index 02584f1950..3497abe503 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/slive/OperationOutput.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/slive/OperationOutput.java @@ -46,7 +46,7 @@ class OperationOutput { private static final String MEASUREMENT_SEP = "*"; private static final String STRING_SEP = ";"; - static enum OutputType { + enum OutputType { STRING, FLOAT, LONG, DOUBLE, INTEGER } diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/slive/PathFinder.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/slive/PathFinder.java index 080985b89a..2dfe2ef836 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/slive/PathFinder.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/fs/slive/PathFinder.java @@ -28,7 +28,7 @@ */ class PathFinder { - private static enum Type { + private enum Type { FILE, DIRECTORY } diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapred/GenericMRLoadGenerator.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapred/GenericMRLoadGenerator.java index f67ca1c17e..c0b231184d 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapred/GenericMRLoadGenerator.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapred/GenericMRLoadGenerator.java @@ -232,7 +232,7 @@ public void close() { } } } - static enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } + enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } static class RandomMapOutput extends MapReduceBase implements Mapper { diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapred/MRBench.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapred/MRBench.java index aee50030ab..5286e86ad6 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapred/MRBench.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapred/MRBench.java @@ -48,7 +48,7 @@ public class MRBench extends Configured implements Tool{ private static Path INPUT_DIR = new Path(BASE_DIR, DEFAULT_INPUT_SUB); private static Path OUTPUT_DIR = new Path(BASE_DIR, DEFAULT_OUTPUT_SUB); - public static enum Order {RANDOM, ASCENDING, DESCENDING}; + public enum Order {RANDOM, ASCENDING, DESCENDING}; /** * Takes input format as text lines, runs some processing on it and diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapred/ThreadedMapBenchmark.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapred/ThreadedMapBenchmark.java index f5512327f5..c607bfb060 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapred/ThreadedMapBenchmark.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapred/ThreadedMapBenchmark.java @@ -63,7 +63,7 @@ public class ThreadedMapBenchmark extends Configured implements Tool { // (FACTOR * data_size) should // result in only 1 spill - static enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } + enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } /** * Generates random input data of given size with keys and values of given diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/GenericMRLoadGenerator.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/GenericMRLoadGenerator.java index 7ee28dfa32..66b7cb8bb3 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/GenericMRLoadGenerator.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/GenericMRLoadGenerator.java @@ -241,7 +241,7 @@ public void close() { } } } - static enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } + enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } static class RandomMapOutput extends Mapper { StringBuilder sentence = new StringBuilder(); diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/LargeSorter.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/LargeSorter.java index d6d0339d51..333ded9e3d 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/LargeSorter.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/LargeSorter.java @@ -67,7 +67,7 @@ public class LargeSorter extends Configured implements Tool { /** * User counters */ - static enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } + enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } /** * A custom input format that creates virtual inputs of a single string diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/RandomTextWriter.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/RandomTextWriter.java index 6cb3211e1f..0bf30c830b 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/RandomTextWriter.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/RandomTextWriter.java @@ -97,7 +97,7 @@ static int printUsage() { /** * User counters */ - static enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } + enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } static class RandomTextMapper extends Mapper { diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/RandomWriter.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/RandomWriter.java index 67c9ca8f0f..b1093f0d94 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/RandomWriter.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/RandomWriter.java @@ -89,7 +89,7 @@ public class RandomWriter extends Configured implements Tool { /** * User counters */ - static enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } + enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } /** * A custom input format that creates virtual inputs of a single string diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/TimelineServicePerformance.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/TimelineServicePerformance.java index 7fa0444840..b5b3d35c27 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/TimelineServicePerformance.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-jobclient/src/test/java/org/apache/hadoop/mapreduce/TimelineServicePerformance.java @@ -157,7 +157,7 @@ public static boolean parseArgs(String[] args, Job job) throws IOException { /** * TimelineServer Performance counters */ - static enum PerfCounters { + enum PerfCounters { TIMELINE_SERVICE_WRITE_TIME, TIMELINE_SERVICE_WRITE_COUNTER, TIMELINE_SERVICE_WRITE_FAILURES, diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-examples/src/main/java/org/apache/hadoop/examples/RandomTextWriter.java b/hadoop-mapreduce-project/hadoop-mapreduce-examples/src/main/java/org/apache/hadoop/examples/RandomTextWriter.java index 6309ee67e5..7e6c099a06 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-examples/src/main/java/org/apache/hadoop/examples/RandomTextWriter.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-examples/src/main/java/org/apache/hadoop/examples/RandomTextWriter.java @@ -97,7 +97,7 @@ static int printUsage() { /** * User counters */ - static enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } + enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } static class RandomTextMapper extends Mapper { diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-examples/src/main/java/org/apache/hadoop/examples/RandomWriter.java b/hadoop-mapreduce-project/hadoop-mapreduce-examples/src/main/java/org/apache/hadoop/examples/RandomWriter.java index 8f322b154e..904b325a6f 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-examples/src/main/java/org/apache/hadoop/examples/RandomWriter.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-examples/src/main/java/org/apache/hadoop/examples/RandomWriter.java @@ -89,7 +89,7 @@ public class RandomWriter extends Configured implements Tool { /** * User counters */ - static enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } + enum Counters { RECORDS_WRITTEN, BYTES_WRITTEN } /** * A custom input format that creates virtual inputs of a single string diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-examples/src/main/java/org/apache/hadoop/examples/terasort/TeraGen.java b/hadoop-mapreduce-project/hadoop-mapreduce-examples/src/main/java/org/apache/hadoop/examples/terasort/TeraGen.java index 7fbb22af63..53bbdc4bcf 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-examples/src/main/java/org/apache/hadoop/examples/terasort/TeraGen.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-examples/src/main/java/org/apache/hadoop/examples/terasort/TeraGen.java @@ -68,7 +68,7 @@ public class TeraGen extends Configured implements Tool { private static final Log LOG = LogFactory.getLog(TeraGen.class); - public static enum Counters {CHECKSUM} + public enum Counters {CHECKSUM} /** * An input format that assigns ranges of longs to each mapper.