Made fixes for whitespace errors and checstyle warnings before merge.

This commit is contained in:
Varun Saxena 2017-08-30 01:17:40 +05:30
parent 512068a01f
commit 3d00c8f394
13 changed files with 38 additions and 38 deletions

View File

@ -142,7 +142,6 @@ import org.apache.hadoop.yarn.server.resourcemanager.scheduler.common.fica.FiCaS
import org.apache.hadoop.yarn.server.resourcemanager.scheduler.event.SchedulerEvent;
import org.apache.hadoop.yarn.server.resourcemanager.scheduler.fifo.FifoScheduler;
import org.apache.hadoop.yarn.server.resourcemanager.security.AMRMTokenSecretManager;
import org.apache.hadoop.yarn.server.timelineservice.security.TimelineV2DelegationTokenSecretManagerService.TimelineV2DelegationTokenSecretManager;
import org.apache.hadoop.yarn.server.utils.BuilderUtils;
import org.apache.hadoop.yarn.util.Clock;
import org.apache.hadoop.yarn.util.ControlledClock;
@ -3585,15 +3584,15 @@ public class TestRMContainerAllocator {
}
}
private static class MockSchedulerForTimelineCollector
private final static class MockSchedulerForTimelineCollector
implements ApplicationMasterProtocol {
CollectorInfo collectorInfo;
private CollectorInfo collectorInfo;
public MockSchedulerForTimelineCollector(CollectorInfo info) {
private MockSchedulerForTimelineCollector(CollectorInfo info) {
this.collectorInfo = info;
}
void updateCollectorInfo(CollectorInfo info) {
private void updateCollectorInfo(CollectorInfo info) {
collectorInfo = info;
}

View File

@ -24,7 +24,6 @@ import org.apache.hadoop.classification.InterfaceAudience.Public;
import org.apache.hadoop.service.CompositeService;
import org.apache.hadoop.yarn.api.records.ApplicationId;
import org.apache.hadoop.yarn.api.records.CollectorInfo;
import org.apache.hadoop.yarn.api.records.Token;
import org.apache.hadoop.yarn.api.records.timelineservice.TimelineEntity;
import org.apache.hadoop.yarn.client.api.impl.TimelineV2ClientImpl;
import org.apache.hadoop.yarn.exceptions.YarnException;

View File

@ -53,7 +53,8 @@ public class TimelineAuthenticationFilterInitializer extends FilterInitializer {
/**
* The configuration prefix of timeline HTTP authentication.
*/
public static final String PREFIX = "yarn.timeline-service.http-authentication.";
public static final String PREFIX =
"yarn.timeline-service.http-authentication.";
@VisibleForTesting
Map<String, String> filterConfig;
@ -104,15 +105,15 @@ public class TimelineAuthenticationFilterInitializer extends FilterInitializer {
}
/**
* Initializes {@link TimelineAuthenticationFilter}
* Initializes {@link TimelineAuthenticationFilter}.
* <p>
* Propagates to {@link TimelineAuthenticationFilter} configuration all YARN
* configuration properties prefixed with {@value #PREFIX}
* configuration properties prefixed with {@value #PREFIX}.
*
* @param container
* The filter container
* The filter container.
* @param conf
* Configuration for run-time parameters
* Configuration for run-time parameters.
*/
@Override
public void initFilter(FilterContainer container, Configuration conf) {

View File

@ -27,7 +27,9 @@ import static org.apache.hadoop.yarn.server.timeline.security.TimelineAuthentica
import org.junit.Test;
import org.mockito.Mockito;
/**
* Tests {@link TimelineAuthenticationFilterInitializer}.
*/
public class TestTimelineAuthenticationFilterInitializer {
@Test

View File

@ -33,12 +33,13 @@ import org.apache.hadoop.yarn.server.nodemanager.api.LocalizationProtocolPB;
@InterfaceStability.Unstable
public class NMPolicyProvider extends PolicyProvider {
private static final Service[] nodeManagerServices =
private static final Service[] NODE_MANAGER_SERVICES =
new Service[] {
new Service(
YarnConfiguration.YARN_SECURITY_SERVICE_AUTHORIZATION_CONTAINER_MANAGEMENT_PROTOCOL,
new Service(YarnConfiguration.
YARN_SECURITY_SERVICE_AUTHORIZATION_CONTAINER_MANAGEMENT_PROTOCOL,
ContainerManagementProtocolPB.class),
new Service(YarnConfiguration.YARN_SECURITY_SERVICE_AUTHORIZATION_RESOURCE_LOCALIZER,
new Service(YarnConfiguration.
YARN_SECURITY_SERVICE_AUTHORIZATION_RESOURCE_LOCALIZER,
LocalizationProtocolPB.class),
new Service(YarnConfiguration.
YARN_SECURITY_SERVICE_AUTHORIZATION_COLLECTOR_NODEMANAGER_PROTOCOL,
@ -47,7 +48,6 @@ public class NMPolicyProvider extends PolicyProvider {
@Override
public Service[] getServices() {
return nodeManagerServices;
return NODE_MANAGER_SERVICES;
}
}

View File

@ -58,7 +58,7 @@ public enum AppToFlowColumnPrefix implements ColumnPrefix<AppToFlowTable> {
private final String columnPrefix;
private final byte[] columnPrefixBytes;
private AppToFlowColumnPrefix(ColumnFamily<AppToFlowTable> columnFamily,
AppToFlowColumnPrefix(ColumnFamily<AppToFlowTable> columnFamily,
String columnPrefix) {
this.columnFamily = columnFamily;
this.columnPrefix = columnPrefix;

View File

@ -91,9 +91,8 @@ public final class EntityTypeReader extends AbstractTimelineStorageReader {
int counter = 0;
while (true) {
try (ResultScanner results
= getResult(hbaseConf, conn, typeFilterList, currRowKey, nextRowKey))
{
try (ResultScanner results =
getResult(hbaseConf, conn, typeFilterList, currRowKey, nextRowKey)) {
TimelineEntity entity = parseEntityForType(results.next());
if (entity == null) {
break;