YARN-852. Merging change r1494733 from trunk to branch-2.
git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1494735 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
84e902a0d3
commit
e597eaf136
|
@ -660,6 +660,9 @@ Release 2.1.0-beta - UNRELEASED
|
||||||
YARN-597. TestFSDownload fails on Windows due to dependencies on
|
YARN-597. TestFSDownload fails on Windows due to dependencies on
|
||||||
tar/gzip/jar tools. (Ivan Mitic via acmurthy)
|
tar/gzip/jar tools. (Ivan Mitic via acmurthy)
|
||||||
|
|
||||||
|
YARN-852. TestAggregatedLogFormat.testContainerLogsFileAccess fails on
|
||||||
|
Windows. (Chuan Liu via cnauroth)
|
||||||
|
|
||||||
YARN-795. Fair scheduler queue metrics should subtract allocated vCores from
|
YARN-795. Fair scheduler queue metrics should subtract allocated vCores from
|
||||||
available vCores. (ywskycn via tucu)
|
available vCores. (ywskycn via tucu)
|
||||||
|
|
||||||
|
|
|
@ -207,26 +207,33 @@ public class TestAggregatedLogFormat {
|
||||||
}
|
}
|
||||||
line = sb.toString();
|
line = sb.toString();
|
||||||
|
|
||||||
|
String expectedOwner = ugi.getShortUserName();
|
||||||
|
if (Path.WINDOWS) {
|
||||||
|
final String adminsGroupString = "Administrators";
|
||||||
|
if (Arrays.asList(ugi.getGroupNames()).contains(adminsGroupString)) {
|
||||||
|
expectedOwner = adminsGroupString;
|
||||||
|
}
|
||||||
|
}
|
||||||
String stdoutFile1 =
|
String stdoutFile1 =
|
||||||
StringUtils.join(
|
StringUtils.join(
|
||||||
Path.SEPARATOR,
|
File.separator,
|
||||||
Arrays.asList(new String[] {
|
Arrays.asList(new String[] {
|
||||||
srcFileRoot.toUri().toString(),
|
workDir.getAbsolutePath(), "srcFiles",
|
||||||
testContainerId1.getApplicationAttemptId().getApplicationId()
|
testContainerId1.getApplicationAttemptId().getApplicationId()
|
||||||
.toString(), testContainerId1.toString(), stderr }));
|
.toString(), testContainerId1.toString(), stderr }));
|
||||||
String message1 =
|
String message1 =
|
||||||
"Owner '" + ugi.getShortUserName() + "' for path " + stdoutFile1
|
"Owner '" + expectedOwner + "' for path " + stdoutFile1
|
||||||
+ " did not match expected owner '" + randomUser + "'";
|
+ " did not match expected owner '" + randomUser + "'";
|
||||||
|
|
||||||
String stdoutFile2 =
|
String stdoutFile2 =
|
||||||
StringUtils.join(
|
StringUtils.join(
|
||||||
Path.SEPARATOR,
|
File.separator,
|
||||||
Arrays.asList(new String[] {
|
Arrays.asList(new String[] {
|
||||||
srcFileRoot.toUri().toString(),
|
workDir.getAbsolutePath(), "srcFiles",
|
||||||
testContainerId1.getApplicationAttemptId().getApplicationId()
|
testContainerId1.getApplicationAttemptId().getApplicationId()
|
||||||
.toString(), testContainerId1.toString(), stdout }));
|
.toString(), testContainerId1.toString(), stdout }));
|
||||||
String message2 =
|
String message2 =
|
||||||
"Owner '" + ugi.getShortUserName() + "' for path "
|
"Owner '" + expectedOwner + "' for path "
|
||||||
+ stdoutFile2 + " did not match expected owner '"
|
+ stdoutFile2 + " did not match expected owner '"
|
||||||
+ ugi.getShortUserName() + "'";
|
+ ugi.getShortUserName() + "'";
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue