Class Client
- All Implemented Interfaces:
Configurable,Tool
ApplicationMaster, which is responsible for managing the lifetime of
the application.
The Dynamometer YARN application starts up the DataNodes of an HDFS cluster. If the namenode_servicerpc_addr option is specified, it should point to the service RPC address of an existing namenode, which the datanodes will talk to. Else, a namenode will be launched internal to this YARN application. The ApplicationMaster's logs contain links to the NN / DN containers to be able to access their logs. Some of this information is also printed by the client.
The application will store files in the submitting user's home directory under a `.dynamometer/applicationID/` folder. This is mostly for uses internal to the application, but if the NameNode is launched through YARN, the NameNode's metrics will also be uploaded to a file `namenode_metrics` within this folder. This file is also accessible as part of the NameNode's logs, but this centralized location is easier to access for subsequent parsing.
If the NameNode is launched internally, this Client will monitor the
status of the NameNode, printing information about its availability as the
DataNodes register (e.g., outstanding under replicated blocks as block
reports arrive). If this is configured to launch the workload job, once the
NameNode has gathered information from all of its DataNodes, the client will
launch a workload job which is configured to act against the newly launched
NameNode. Once the workload job completes, the infrastructure application
will be shut down. At this time only the audit log replay
(AuditReplayMapper) workload is supported.
If there is no workload job configured, this application will, by default, persist indefinitely until killed by YARN. You can specify the timeout option to have it exit automatically after some time. This timeout will enforced if there is a workload job configured as well.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidBest-effort attempt to clean up any remaining applications (infrastructure or workload).booleanParse command line options.static voidbooleanrun()Main run function for the client.intExecute the command with the given arguments.Methods inherited from class org.apache.hadoop.conf.Configured
getConf, setConfMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.hadoop.conf.Configurable
getConf, setConf
-
Field Details
-
APPNAME_ARG
- See Also:
-
APPNAME_DEFAULT
- See Also:
-
QUEUE_ARG
- See Also:
-
QUEUE_DEFAULT
- See Also:
-
TIMEOUT_ARG
- See Also:
-
TIMEOUT_DEFAULT
- See Also:
-
HADOOP_VERSION_ARG
- See Also:
-
HADOOP_BINARY_PATH_ARG
- See Also:
-
NAMENODE_SERVICERPC_ADDR_ARG
- See Also:
-
FS_IMAGE_DIR_ARG
- See Also:
-
BLOCK_LIST_PATH_ARG
- See Also:
-
CONF_PATH_ARG
- See Also:
-
MASTER_VCORES_ARG
- See Also:
-
MASTER_VCORES_DEFAULT
- See Also:
-
MASTER_MEMORY_MB_ARG
- See Also:
-
MASTER_MEMORY_MB_DEFAULT
- See Also:
-
TOKEN_FILE_LOCATION_ARG
- See Also:
-
WORKLOAD_REPLAY_ENABLE_ARG
- See Also:
-
WORKLOAD_INPUT_PATH_ARG
- See Also:
-
WORKLOAD_OUTPUT_PATH_ARG
- See Also:
-
WORKLOAD_THREADS_PER_MAPPER_ARG
- See Also:
-
WORKLOAD_START_DELAY_ARG
- See Also:
-
WORKLOAD_RATE_FACTOR_ARG
- See Also:
-
WORKLOAD_RATE_FACTOR_DEFAULT
- See Also:
-
WORKLOAD_CONFIG_ARG
- See Also:
-
-
Constructor Details
-
Client
-
-
Method Details
-
main
- Parameters:
args- Command line arguments- Throws:
Exception- on error
-
run
Description copied from interface:ToolExecute the command with the given arguments. -
init
Parse command line options.- Parameters:
args- Parsed command line options- Returns:
- Whether the init was successful to run the client
- Throws:
org.apache.commons.cli.ParseException- on error while parsingIOException- for other errors
-
run
Main run function for the client.- Returns:
- true if application completed successfully
- Throws:
IOException- for general issuesYarnException- for issues while contacting YARN daemons
-
attemptCleanup
public void attemptCleanup()Best-effort attempt to clean up any remaining applications (infrastructure or workload).
-