YARN-8339. Service AM should localize static/archive resource types to container working directory instead of 'resources'. (Suma Shivaprasad via wangda)
Change-Id: I9f8e8f621650347f6c2f9e3420edee9eb2f356a4
This commit is contained in:
parent
3c75f8e493
commit
3061bfcde5
|
@ -298,8 +298,7 @@ public class ProviderUtils implements YarnServiceConstants {
|
|||
destFile = new Path(staticFile.getDestFile());
|
||||
}
|
||||
|
||||
String symlink = APP_RESOURCES_DIR + "/" + destFile.getName();
|
||||
addLocalResource(launcher, symlink, localResource, destFile);
|
||||
addLocalResource(launcher, destFile.getName(), localResource, destFile);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -154,11 +154,11 @@ public class TestProviderUtils {
|
|||
|
||||
ProviderUtils.handleStaticFilesForLocalization(launcher, sfs,
|
||||
compLaunchCtx);
|
||||
Mockito.verify(launcher).addLocalResource(Mockito.eq("resources/destFile1"),
|
||||
Mockito.verify(launcher).addLocalResource(Mockito.eq("destFile1"),
|
||||
any(LocalResource.class));
|
||||
Mockito.verify(launcher).addLocalResource(
|
||||
Mockito.eq("resources/destFile_2"), any(LocalResource.class));
|
||||
Mockito.eq("destFile_2"), any(LocalResource.class));
|
||||
Mockito.verify(launcher).addLocalResource(
|
||||
Mockito.eq("resources/sourceFile4"), any(LocalResource.class));
|
||||
Mockito.eq("sourceFile4"), any(LocalResource.class));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue