-
Notifications
You must be signed in to change notification settings - Fork 240
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Deploy release candidates to local maven repo for dependency check[skip ci] #10201
Changes from 1 commit
adfef12
4442749
9ae974f
dd32789
94f3078
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
#!/bin/bash | ||
# | ||
# Copyright (c) 2020-2023, NVIDIA CORPORATION. All rights reserved. | ||
# Copyright (c) 2020-2024, NVIDIA CORPORATION. All rights reserved. | ||
# | ||
# Licensed under the Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
|
@@ -50,6 +50,12 @@ ART_VER=$(mvnEval $DIST_PL project.version) | |
DEFAULT_CUDA_CLASSIFIER=$(mvnEval $DIST_PL cuda.version) | ||
CUDA_CLASSIFIERS=${CUDA_CLASSIFIERS:-"$DEFAULT_CUDA_CLASSIFIER"} | ||
CLASSIFIERS=${CLASSIFIERS:-"$CUDA_CLASSIFIERS"} # default as CUDA_CLASSIFIERS for compatibility | ||
SERVER_ID=${SERVER_ID:-"snapshots"} | ||
SERVER_URL=${SERVER_URL:-"file:/tmp/local-release-repo"} | ||
# Save to be deployed artifact list into the file, e.g. | ||
ARTIFACT_FILE=${ARTIFACT_FILE:-"/tmp/artifact-file"} | ||
# Clean rtifact list file befor saving | ||
rm -rf $ARTIFACT_FILE | ||
|
||
SQL_PL=${SQL_PL:-"sql-plugin"} | ||
POM_FILE=${POM_FILE:-"$DIST_PL/target/parallel-world/META-INF/maven/${ART_GROUP_ID}/${ART_ID}/pom.xml"} | ||
|
@@ -63,7 +69,7 @@ DEPLOY_TYPES=$(echo $CLASSIFIERS | sed -e 's;[^,]*;jar;g') | |
DEPLOY_FILES=$(echo $CLASSIFIERS | sed -e "s;\([^,]*\);${FPATH}-\1.jar;g") | ||
|
||
# dist does not have javadoc and sources jars, use 'sql-plugin' instead | ||
source jenkins/version-def.sh >/dev/null 2&>1 | ||
source jenkins/version-def.sh >/dev/null 2>&1 | ||
echo $SPARK_BASE_SHIM_VERSION | ||
SQL_ART_ID=$(mvnEval $SQL_PL project.artifactId) | ||
SQL_ART_VER=$(mvnEval $SQL_PL project.version) | ||
|
@@ -96,6 +102,14 @@ echo "Deploy CMD: $DEPLOY_CMD" | |
|
||
###### Deploy the parent pom file ###### | ||
$DEPLOY_CMD -Dfile=./pom.xml -DpomFile=./pom.xml | ||
PARENT_ART_ID=$(mvnEval "./" project.artifactId) | ||
echo "$ART_GROUP_ID:$PARENT_ART_ID:$ART_VER:pom" >> $ARTIFACT_FILE | ||
|
||
###### Deploy the jdk-profile pom file ###### | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Deploy pom.xml file of the module |
||
JDK_PROFILES=${JDK_PROFILES:-"jdk-profiles"} | ||
$DEPLOY_CMD -Dfile=$JDK_PROFILES/pom.xml -DpomFile=$JDK_PROFILES/pom.xml | ||
JDK_PROFILES_ART_ID=$(mvnEval "$JDK_PROFILES" project.artifactId) | ||
echo "$ART_GROUP_ID:$JDK_PROFILES_ART_ID:$ART_VER:pom" >> $ARTIFACT_FILE | ||
|
||
###### Deploy the artifact jar(s) ###### | ||
$DEPLOY_CMD -DpomFile=$POM_FILE \ | ||
|
@@ -105,3 +119,11 @@ $DEPLOY_CMD -DpomFile=$POM_FILE \ | |
-Dfiles=$DEPLOY_FILES \ | ||
-Dtypes=$DEPLOY_TYPES \ | ||
-Dclassifiers=$CLASSIFIERS | ||
|
||
echo "$ART_GROUP_ID:$ART_ID:$ART_VER:pom" >> $ARTIFACT_FILE | ||
echo "$ART_GROUP_ID:$ART_ID:$ART_VER:jar" >> $ARTIFACT_FILE | ||
CLASSLIST="$CLASSIFIERS,sources,javadoc" | ||
CLASSLIST=(${CLASSLIST//','/' '}) | ||
for class in ${CLASSLIST[@]}; do | ||
echo "$ART_GROUP_ID:$ART_ID:$ART_VER:jar:$class" >> $ARTIFACT_FILE | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The artifact file is like below, and our plugin nightly build CI will check all these artifacts dependencies.
|
||
done |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -30,7 +30,7 @@ WORKSPACE=${WORKSPACE:-$(pwd)} | |
export M2DIR=${M2DIR:-"$WORKSPACE/.m2"} | ||
|
||
## MVN_OPT : maven options environment, e.g. MVN_OPT='-Dspark-rapids-jni.version=xxx' to specify spark-rapids-jni dependency's version. | ||
MVN="mvn -Dmaven.wagon.http.retryHandler.count=3 -DretryFailedDeploymentCount=3 ${MVN_OPT}" | ||
MVN="mvn -Dmaven.wagon.http.retryHandler.count=3 -DretryFailedDeploymentCount=3 ${MVN_OPT} -Psource-javadoc" | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Generate these 2 files to mimic OSS release in our nightly build CI |
||
|
||
DIST_PL="dist" | ||
function mvnEval { | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
save artifact like
com.nvidia:rapids-4-spark-parent_2.12:24.02.0-SNAPSHOT:pom
into $ARTIFACT_FILEThere was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To elaborate on the previous comment, we don't have to register intermediate pom for an explicit check via an $ARTIFACT_FILE line.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated