public final class YarnSubmissionHelper extends Object implements Closeable
Constructor and Description |
---|
YarnSubmissionHelper(org.apache.hadoop.yarn.conf.YarnConfiguration yarnConfiguration,
REEFFileNames fileNames,
ClasspathProvider classpath,
SecurityTokenProvider tokenProvider) |
YarnSubmissionHelper(org.apache.hadoop.yarn.conf.YarnConfiguration yarnConfiguration,
REEFFileNames fileNames,
ClasspathProvider classpath,
SecurityTokenProvider tokenProvider,
List<String> commandPrefixList) |
Modifier and Type | Method and Description |
---|---|
YarnSubmissionHelper |
addLocalResource(String resourceName,
org.apache.hadoop.yarn.api.records.LocalResource resource)
Add a file to be localized on the driver.
|
void |
close() |
int |
getApplicationId() |
String |
getStringApplicationId() |
YarnSubmissionHelper |
setApplicationName(String applicationName)
Set the name of the application to be submitted.
|
YarnSubmissionHelper |
setConfigurationFilePaths(List<String> configurationFilePaths)
Sets the configuration file for the job.
|
YarnSubmissionHelper |
setDriverMemory(int megabytes)
Set the amount of memory to be allocated to the Driver.
|
YarnSubmissionHelper |
setLauncherClass(Class launcherClass)
Sets the launcher class for the job.
|
YarnSubmissionHelper |
setMaxApplicationAttempts(int maxApplicationAttempts)
Sets the maximum application attempts for the application.
|
YarnSubmissionHelper |
setPreserveEvaluators(boolean preserveEvaluators)
Set whether or not the resource manager should preserve evaluators across driver restarts.
|
YarnSubmissionHelper |
setPriority(int priority)
Set the priority of the job.
|
YarnSubmissionHelper |
setQueue(String queueName)
Assign this job submission to a queue.
|
void |
submit() |
public YarnSubmissionHelper(org.apache.hadoop.yarn.conf.YarnConfiguration yarnConfiguration, REEFFileNames fileNames, ClasspathProvider classpath, SecurityTokenProvider tokenProvider, List<String> commandPrefixList) throws IOException, org.apache.hadoop.yarn.exceptions.YarnException
IOException
org.apache.hadoop.yarn.exceptions.YarnException
public YarnSubmissionHelper(org.apache.hadoop.yarn.conf.YarnConfiguration yarnConfiguration, REEFFileNames fileNames, ClasspathProvider classpath, SecurityTokenProvider tokenProvider) throws IOException, org.apache.hadoop.yarn.exceptions.YarnException
IOException
org.apache.hadoop.yarn.exceptions.YarnException
public int getApplicationId()
public String getStringApplicationId()
public YarnSubmissionHelper setApplicationName(String applicationName)
applicationName
- public YarnSubmissionHelper setDriverMemory(int megabytes)
megabytes
- public YarnSubmissionHelper addLocalResource(String resourceName, org.apache.hadoop.yarn.api.records.LocalResource resource)
resourceName
- resource
- public YarnSubmissionHelper setPriority(int priority)
priority
- public YarnSubmissionHelper setPreserveEvaluators(boolean preserveEvaluators)
preserveEvaluators
- public YarnSubmissionHelper setMaxApplicationAttempts(int maxApplicationAttempts)
maxApplicationAttempts
- public YarnSubmissionHelper setQueue(String queueName)
queueName
- public YarnSubmissionHelper setLauncherClass(Class launcherClass)
launcherClass
- public YarnSubmissionHelper setConfigurationFilePaths(List<String> configurationFilePaths)
configurationFilePaths
- public void submit() throws IOException, org.apache.hadoop.yarn.exceptions.YarnException
IOException
org.apache.hadoop.yarn.exceptions.YarnException
public void close() throws IOException
close
in interface Closeable
close
in interface AutoCloseable
IOException
Copyright © 2016 The Apache Software Foundation. All rights reserved.