Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1028,6 +1028,7 @@
<order>java,javax,org.apache,com,net,io</order>
</importOrder>
<removeUnusedImports/>
<trimTrailingWhitespace/>
</java>
</configuration>
</plugin>
Expand Down
10 changes: 5 additions & 5 deletions tez-api/src/main/java/org/apache/tez/client/AMConfiguration.java
Original file line number Diff line number Diff line change
Expand Up @@ -50,15 +50,15 @@ class AMConfiguration {
void addAMLocalResources(Map<String, LocalResource> localResources) {
this.amLocalResources.putAll(localResources);
}

void clearAMLocalResources() {
this.amLocalResources.clear();
}

void setCredentials(Credentials credentials) {
this.credentials = credentials;
}

void setTezConfiguration(TezConfiguration tezConf) {
this.tezConf = tezConf;
}
Expand All @@ -78,11 +78,11 @@ TezConfiguration getTezConfiguration() {
Credentials getCredentials() {
return credentials;
}

void setBinaryConfLR(LocalResource binaryConfLRsrc) {
this.binaryConfLRsrc = binaryConfLRsrc;
}

LocalResource getBinaryConfLR() {
return binaryConfLRsrc;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,16 +33,16 @@ public interface ContainerSignatureMatcher {
* signature.
*/
public boolean isSuperSet(Object cs1, Object cs2);

/**
* Checks if the container signatures match exactly
* @return true if exact match
*/
public boolean isExactMatch(Object cs1, Object cs2);

/**
* Gets additional resources specified in lr2, which are not present for lr1
*
*
* @param lr1
* @param lr2
* @return additional resources specified in lr2, which are not present for lr1
Expand Down
10 changes: 5 additions & 5 deletions tez-api/src/main/java/org/apache/tez/common/TezYARNUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
* licenses this file to you under the Apache License, Version 2.0 (the
* "License"); you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
*
* http://www.apache.org/licenses/LICENSE-2.0
*
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
Expand Down Expand Up @@ -162,7 +162,7 @@ public static void appendToEnvFromInputString(Map<String, String> env,
}
}
}

public static void setEnvIfAbsentFromInputString(Map<String, String> env,
String envString) {
if (envString != null && envString.length() > 0) {
Expand All @@ -189,7 +189,7 @@ public static void setEnvIfAbsentFromInputString(Map<String, String> env,
}
}
}

public static void addToEnvironment(
Map<String, String> environment,
String variable, String value, String classPathSeparator) {
Expand All @@ -199,7 +199,7 @@ public static void addToEnvironment(
} else {
val = val + classPathSeparator + value;
}
environment.put(StringInterner.weakIntern(variable),
environment.put(StringInterner.weakIntern(variable),
StringInterner.weakIntern(val));
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

@SuppressWarnings("rawtypes")
public class AggregateFrameworkCounter<T extends Enum<T>> extends FrameworkCounter implements AggregateTezCounter {

private long min = Long.MAX_VALUE;
private long max = Long.MIN_VALUE;
private long count = 0;
Expand All @@ -36,7 +36,7 @@ public AggregateFrameworkCounter(Enum<T> ref, String groupName) {
public void increment(long incr) {
throw new IllegalArgumentException("Cannot increment an aggregate counter directly");
}

@Override
public void aggregate(TezCounter other) {
final long val = other.getValue();
Expand Down Expand Up @@ -71,7 +71,7 @@ public long getMin() {
public long getMax() {
return max;
}

@SuppressWarnings("unchecked")
public FrameworkCounter<T> asFrameworkCounter() {
return ((FrameworkCounter<T>)this);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public interface AggregateTezCounter {
public abstract long getMin();

public abstract long getMax();

public abstract long getCount();

}
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ public class AggregateTezCounterDelegate<T extends TezCounter> extends AbstractC
public AggregateTezCounterDelegate(T child) {
this.child = child;
}

@Override
public String getName() {
return child.getName(); // this is a pass-through
Expand All @@ -57,7 +57,7 @@ public void setValue(long value) {
public void increment(long incr) {
throw new UnsupportedOperationException("Cannot increment an aggregate counter");
}

/* (non-Javadoc)
* @see org.apache.tez.common.counters.AggregateTezCounter#aggregate(org.apache.tez.common.counters.TezCounter)
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,13 @@
package org.apache.tez.common.counters;

public class AggregateTezCounters extends TezCounters {

private static final GroupFactory groupFactory = new GroupFactory();

public AggregateTezCounters() {
super(groupFactory);
}

// Mix framework group implementation into CounterGroup interface
private static class AggregateFrameworkGroupImpl<T extends Enum<T>>
extends FrameworkCounterGroup<T, TezCounter> implements CounterGroup {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
@InterfaceAudience.Public
@InterfaceStability.Evolving
public enum DAGCounter {
NUM_FAILED_TASKS,
NUM_FAILED_TASKS,
NUM_KILLED_TASKS,
NUM_SUCCEEDED_TASKS,
TOTAL_LAUNCHED_TASKS,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
// Per-job counters
@Private
public enum JobCounter {
NUM_FAILED_MAPS,
NUM_FAILED_MAPS,
NUM_FAILED_REDUCES,
NUM_KILLED_MAPS,
NUM_KILLED_REDUCES,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@

@InterfaceAudience.Private
public class Limits {

private static final Logger LOG = LoggerFactory.getLogger(Limits.class);

private static final Configuration DEFAULT_CONFIGURATION = new TezConfiguration();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
public class JobTokenIdentifier extends TokenIdentifier {
private Text jobid;
public final static Text KIND_NAME = new Text("tez.job");

/**
* Default constructor
*/
Expand All @@ -58,7 +58,7 @@ public JobTokenIdentifier(Text jobid) {
public Text getKind() {
return KIND_NAME;
}

/** {@inheritDoc} */
@Override
public UserGroupInformation getUser() {
Expand All @@ -67,7 +67,7 @@ public UserGroupInformation getUser() {
}
return UserGroupInformation.createRemoteUser(jobid.toString());
}

/**
* Get the jobid
* @return the jobid
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ public void removeTokenForJob(String jobId) {
currentJobTokens.remove(jobId);
}
}

/**
* Look up the token password/secret for the given jobId.
* @param jobId the jobId to look up
Expand All @@ -146,7 +146,7 @@ public SecretKey retrieveTokenSecret(String jobId) throws InvalidToken {
}
return tokenSecret;
}

/**
* Look up the token password/secret for the given job token identifier.
* @param identifier the job token identifier to look up
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public static String getMasterUserName(Configuration conf) {
return conf.get(YarnConfiguration.RM_PRINCIPAL);
}


// This needs to go into YARN
public static InetSocketAddress getMasterAddress(Configuration conf) {
return conf
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,17 +42,17 @@
* This class provides user facing APIs for transferring secrets from
* the job client to the tasks.
* The secrets can be stored just before submission of jobs and read during
* the task execution.
* the task execution.
*/
@InterfaceAudience.Private
@InterfaceStability.Unstable
public final class TokenCache {

private static final Logger LOG = LoggerFactory.getLogger(TokenCache.class);

private TokenCache() {}


/**
* auxiliary method to get user's secret keys..
*
Expand All @@ -63,9 +63,9 @@ public static byte[] getSecretKey(Credentials credentials, Text alias) {
return null;
return credentials.getSecretKey(alias);
}

/**
* Convenience method to obtain delegation tokens from namenodes
* Convenience method to obtain delegation tokens from namenodes
* corresponding to the paths passed.
* @param credentials credentials
* @param ps array of paths
Expand Down Expand Up @@ -121,7 +121,7 @@ static boolean isTokenRenewalExcluded(FileSystem fs, Configuration conf) {
/**
* get delegation token for a specific FS
*/
static void obtainTokensForFileSystemsInternal(FileSystem fs,
static void obtainTokensForFileSystemsInternal(FileSystem fs,
Credentials credentials, Configuration conf) throws IOException {
// TODO Change this to use YARN utilities once YARN-1664 is fixed.
// RM skips renewing token with empty renewer
Expand Down Expand Up @@ -149,12 +149,12 @@ static void obtainTokensForFileSystemsInternal(FileSystem fs,
* store session specific token
*/
@InterfaceAudience.Private
public static void setSessionToken(Token<? extends TokenIdentifier> t,
public static void setSessionToken(Token<? extends TokenIdentifier> t,
Credentials credentials) {
credentials.addToken(SESSION_TOKEN, t);
}
/**
*
*
* @return session token
*/
@SuppressWarnings("unchecked")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ public static PlanLocalResourceVisibility convertToDAGPlan(LocalResourceVisibili
default : throw new RuntimeException("unknown 'visibility': " + visibility);
}
}

public static List<PlanLocalResource> convertToDAGPlan(Map<String, LocalResource> lrs) {
List<PlanLocalResource> planLrs = Lists.newArrayListWithCapacity(lrs.size());
for (Entry<String, LocalResource> entry : lrs.entrySet()) {
Expand Down Expand Up @@ -224,7 +224,7 @@ public static VertexLocationHint convertFromDAGPlan(
}
return VertexLocationHint.create(outputList);
}

public static String convertToDAGPlan(URL resource) {
Path p;
try {
Expand Down Expand Up @@ -281,7 +281,7 @@ public static Map<String, EdgePlan> createEdgePlanMapFromDAGPlan(List<EdgePlan>
}
return edgePlanMap;
}

public static PlanEdgeProperty convertToProto(EdgeProperty prop) {
PlanEdgeProperty.Builder edgePropBuilder = PlanEdgeProperty.newBuilder();
edgePropBuilder.setDataMovementType(convertToDAGPlan(prop.getDataMovementType()));
Expand All @@ -294,10 +294,10 @@ public static PlanEdgeProperty convertToProto(EdgeProperty prop) {
edgePropBuilder.setEdgeManager(DagTypeConverters.convertToDAGPlan(prop
.getEdgeManagerDescriptor()));
}

return edgePropBuilder.build();
}

public static EdgeProperty convertFromProto(PlanEdgeProperty edge) {
return EdgeProperty.create(
(edge.hasEdgeManager() ?
Expand Down
Loading