Skip to content

Commit

Permalink
Smoke test with '--package' to fetch the plugin jar (#10238)
Browse files Browse the repository at this point in the history
* Smoke test with '--package' to fetch the plugin jar

To fix #10160

Run SPARK_SHELL_SMOKE_TEST with '--package' to fetch the plugin jar

Can downloading the plugin jar from specified artifact repo by '--repositories'

This test can fetch plugin jar from internal maven repo, maven central, or Sonatype staging repo.

Signed-off-by: Tim Liu <timl@nvidia.com>

* Update integration_tests/run_pyspark_from_build.sh

This suggestion is reasonable

Co-authored-by: Jason Lowe <jlowe@nvidia.com>

* not nest the 'repositories' parameter

Signed-off-by: Tim Liu <timl@nvidia.com>

---------

Signed-off-by: Tim Liu <timl@nvidia.com>
Co-authored-by: Jason Lowe <jlowe@nvidia.com>
  • Loading branch information
NvTimLiu and jlowe authored Jan 23, 2024
1 parent e51481e commit 5b4c575
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
7 changes: 6 additions & 1 deletion integration_tests/run_pyspark_from_build.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#!/bin/bash
# Copyright (c) 2020-2023, NVIDIA CORPORATION.
# Copyright (c) 2020-2024, NVIDIA CORPORATION.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand Down Expand Up @@ -333,10 +333,15 @@ EOF
--driver-class-path "${PYSP_TEST_spark_driver_extraClassPath}"
--conf spark.executor.extraClassPath="${PYSP_TEST_spark_driver_extraClassPath}"
)
elif [[ -n "$PYSP_TEST_spark_jars_packages" ]]; then
SPARK_SHELL_ARGS_ARR+=(--packages "${PYSP_TEST_spark_jars_packages}")
else
SPARK_SHELL_ARGS_ARR+=(--jars "${PYSP_TEST_spark_jars}")
fi

if [[ -n "$PYSP_TEST_spark_jars_repositories" ]]; then
SPARK_SHELL_ARGS_ARR+=(--repositories "${PYSP_TEST_spark_jars_repositories}")
fi
# NOTE grep is used not only for checking the output but also
# to workaround the fact that spark-shell catches all failures.
# In this test it exits not because of the failure but because it encounters
Expand Down
5 changes: 5 additions & 0 deletions jenkins/spark-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,11 @@ if [[ $TEST_MODE == "DEFAULT" ]]; then
PYSP_TEST_spark_shuffle_manager=com.nvidia.spark.rapids.${SHUFFLE_SPARK_SHIM}.RapidsShuffleManager \
./run_pyspark_from_build.sh

SPARK_SHELL_SMOKE_TEST=1 \
PYSP_TEST_spark_jars_packages=com.nvidia:rapids-4-spark_${SCALA_BINARY_VER}:${PROJECT_VER} \
PYSP_TEST_spark_jars_repositories=${PROJECT_REPO} \
./run_pyspark_from_build.sh

# ParquetCachedBatchSerializer cache_test
PYSP_TEST_spark_sql_cache_serializer=com.nvidia.spark.ParquetCachedBatchSerializer \
./run_pyspark_from_build.sh -k cache_test
Expand Down

0 comments on commit 5b4c575

Please sign in to comment.