MAPREDUCE-6521. MiniMRYarnCluster should not create /tmp/hadoop-yarn/staging on local filesystem in unit test.
Contributed by Masatake Iwasaki.
Change-Id: Id74b90eb7cfb9d676188fc5aa47249ee8904a3d5
(cherry picked from commit 79f6118dcc
)
This commit is contained in:
parent
62fdfaf093
commit
1f0bf69e16
|
@ -119,7 +119,9 @@ public class MiniMRYarnCluster extends MiniYARNCluster {
|
|||
@Override
|
||||
public void serviceInit(Configuration conf) throws Exception {
|
||||
conf.set(MRConfig.FRAMEWORK_NAME, MRConfig.YARN_FRAMEWORK_NAME);
|
||||
if (conf.get(MRJobConfig.MR_AM_STAGING_DIR) == null) {
|
||||
String stagingDir = conf.get(MRJobConfig.MR_AM_STAGING_DIR);
|
||||
if (stagingDir == null ||
|
||||
stagingDir.equals(MRJobConfig.DEFAULT_MR_AM_STAGING_DIR)) {
|
||||
conf.set(MRJobConfig.MR_AM_STAGING_DIR, new File(getTestWorkDir(),
|
||||
"apps_staging_dir/").getAbsolutePath());
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue