Add Implementation for Distributed Mode in Qualification Tool CLI #1477
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #1476.
With the merge of arguments for toggling distributed mode in the Qualification Tool CLI, the next step is to implement the functionality for this feature.
Usage
Notes:
Detailed Changes
Support for distributed job submission:
user_tools/src/spark_rapids_pytools/rapids/rapids_job.py
: Implemented the_submit_job
method to support submitting the Tools JAR to a Spark cluster usingDistributedToolsExecutor
.user_tools/src/spark_rapids_tools_distributed/distributed_main.py
: Added a new module to orchestrate the execution of the Spark Rapids Tools JAR on Spark, including environment validation, job submission, and output processing.Enhancements to utility functions:
user_tools/src/spark_rapids_tools/utils/util.py
: Addedparse_memory_size_in_gb
andarchive_directory
methods to convert memory size strings to gigabytes and archive directories, respectively.user_tools/src/spark_rapids_tools/storagelib/csppath.py
: Addedopen_append_stream
method to support appending to files.New dependencies:
user_tools/pyproject.toml
: Addedpyspark
dependency for distributed computing.Other notable changes:
user_tools/src/spark_rapids_pytools/rapids/qualification.py
: Added a check to log a warning and return an empty DataFrame if the report file does not exist.user_tools/src/spark_rapids_tools_distributed/jar_cmd_args.py
: Added cached properties to extract specific JVM arguments and paths from the command arguments.