### What changes were proposed in this pull request? ### Why are the changes needed? ```bash flink-1.18.0 ./bin/start-cluster.sh ./bin/flink run examples/streaming/WordCount.jar --execution-mode BATCH ``` ```java Caused by: java.lang.NoSuchMethodError: org.apache.flink.runtime.io.network.partition.consumer.SingleInputGate.<init>(Ljava/lang/String;ILorg/apache/flink/runtime/jobgraph/IntermediateDataSetID;Lorg/apache/flink/runtime/io/network/partition/ResultPartitionType;Lorg/apache/flink/runtime/executiongraph/IndexRange;ILorg/apache/flink/runtime/io/network/partition/PartitionProducerStateProvider;Lorg/apache/flink/util/function/SupplierWithException;Lorg/apache/flink/runtime/io/network/buffer/BufferDecompressor;Lorg/apache/flink/core/memory/MemorySegmentProvider;ILorg/apache/flink/runtime/throughput/ThroughputCalculator;Lorg/apache/flink/runtime/throughput/BufferDebloater;)V at org.apache.celeborn.plugin.flink.RemoteShuffleInputGate$FakedRemoteInputChannel.<init>(RemoteShuffleInputGate.java:225) at org.apache.celeborn.plugin.flink.RemoteShuffleInputGate.getChannel(RemoteShuffleInputGate.java:179) at org.apache.flink.runtime.io.network.partition.consumer.InputGate.setChannelStateWriter(InputGate.java:90) at org.apache.flink.runtime.taskmanager.InputGateWithMetrics.setChannelStateWriter(InputGateWithMetrics.java:120) at org.apache.flink.streaming.runtime.tasks.StreamTask.injectChannelStateWriterIntoChannels(StreamTask.java:524) at org.apache.flink.streaming.runtime.tasks.StreamTask.<init>(StreamTask.java:496) ``` Flink 1.18.0 release https://flink.apache.org/2023/10/24/announcing-the-release-of-apache-flink-1.18/ Interface `org.apache.flink.runtime.io.network.buffer.Buffer` adds `setRecycler` method. [[FLINK-32549](https://issues.apache.org/jira/browse/FLINK-32549)][network] Tiered storage memory manager supports ownership transfer for buffers `org.apache.flink.runtime.io.network.partition.consumer.SingleInputGate` constructor adds parameters. [[FLINK-31638](https://issues.apache.org/jira/browse/FLINK-31638)][network] Introduce the TieredStorageConsumerClient to SingleInputGate [[FLINK-31642](https://issues.apache.org/jira/browse/FLINK-31642)][network] Introduce the MemoryTierConsumerAgent to TieredStorageConsumerClient ### Does this PR introduce _any_ user-facing change? ### How was this patch tested? ```bash flink-1.18.0 ./bin/flink run examples/streaming/WordCount.jar --execution-mode BATCH Executing example with default input data. Use --input to specify file input. Printing result to stdout. Use --output to specify output path. Job has been submitted with JobID d7fc5f0ca018a54e9453c4d35f7c598a Program execution finished Job with JobID d7fc5f0ca018a54e9453c4d35f7c598a has finished. Job Runtime: 1635 ms ``` <img width="1297" alt="image" src="https://github.com/apache/incubator-celeborn/assets/3898450/6a5266bf-2386-4386-b98b-a60d2570fa99"> Closes #2063 from cxzl25/CELEBORN-1105. Authored-by: sychen <sychen@ctrip.com> Signed-off-by: Shuang <lvshuang.tb@gmail.com>
177 lines
6.8 KiB
Bash
Executable File
177 lines
6.8 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
#
|
|
# Licensed to the Apache Software Foundation (ASF) under one or more
|
|
# contributor license agreements. See the NOTICE file distributed with
|
|
# this work for additional information regarding copyright ownership.
|
|
# The ASF licenses this file to You under the Apache License, Version 2.0
|
|
# (the "License"); you may not use this file except in compliance with
|
|
# the License. You may obtain a copy of the License at
|
|
#
|
|
# http://www.apache.org/licenses/LICENSE-2.0
|
|
#
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
# See the License for the specific language governing permissions and
|
|
# limitations under the License.
|
|
#
|
|
|
|
set -o pipefail
|
|
set -e
|
|
set -x
|
|
|
|
PROJECT_DIR="$(cd "$(dirname "$0")"/../..; pwd)"
|
|
|
|
ASF_USERNAME=${ASF_USERNAME:?"ASF_USERNAME is required"}
|
|
ASF_PASSWORD=${ASF_PASSWORD:?"ASF_PASSWORD is required"}
|
|
RELEASE_RC_NO=${RELEASE_RC_NO:?"RELEASE_RC_NO is required, e.g. 0"}
|
|
|
|
RELEASE_VERSION=$(grep '<project.version>.*</project.version>' "${PROJECT_DIR}/pom.xml" -o \
|
|
| head -n 1 \
|
|
| sed 's/<\/*project.version>//g')
|
|
|
|
exit_with_usage() {
|
|
local NAME=$(basename $0)
|
|
cat << EOF
|
|
Usage: $NAME <publish|finalize>
|
|
|
|
Top level targets are:
|
|
publish: Publish tarballs to SVN staging repository
|
|
finalize: Finalize the release after an RC passes vote
|
|
|
|
All other inputs are environment variables
|
|
|
|
RELEASE_RC_NO - Release RC number, (e.g. 0)
|
|
|
|
ASF_USERNAME - Username of ASF committer account
|
|
ASF_PASSWORD - Password of ASF committer account
|
|
EOF
|
|
exit 1
|
|
}
|
|
|
|
if [[ ${RELEASE_VERSION} =~ .*-SNAPSHOT ]]; then
|
|
echo "Can not release a SNAPSHOT version: ${RELEASE_VERSION}"
|
|
exit_with_usage
|
|
exit 1
|
|
fi
|
|
|
|
RELEASE_TAG="v${RELEASE_VERSION}-rc${RELEASE_RC_NO}"
|
|
|
|
SVN_STAGING_REPO="https://dist.apache.org/repos/dist/dev/incubator/celeborn"
|
|
SVN_RELEASE_REPO="https://dist.apache.org/repos/dist/release/incubator/celeborn"
|
|
|
|
RELEASE_DIR="${PROJECT_DIR}/tmp"
|
|
SVN_STAGING_DIR="${PROJECT_DIR}/tmp/svn-dev"
|
|
SVN_RELEASE_DIR="${PROJECT_DIR}/tmp/svn-release"
|
|
|
|
package() {
|
|
SKIP_GPG="false" $PROJECT_DIR/build/release/create-package.sh source
|
|
SKIP_GPG="false" $PROJECT_DIR/build/release/create-package.sh binary
|
|
}
|
|
|
|
upload_svn_staging() {
|
|
svn checkout --depth=empty "${SVN_STAGING_REPO}" "${SVN_STAGING_DIR}"
|
|
mkdir -p "${SVN_STAGING_DIR}/${RELEASE_TAG}"
|
|
rm -f "${SVN_STAGING_DIR}/${RELEASE_TAG}/*"
|
|
|
|
SRC_TGZ_FILE="apache-celeborn-${RELEASE_VERSION}-source.tgz"
|
|
BIN_TGZ_FILE="apache-celeborn-${RELEASE_VERSION}-bin.tgz"
|
|
|
|
echo "Copying release tarballs"
|
|
cp "${RELEASE_DIR}/${SRC_TGZ_FILE}" "${SVN_STAGING_DIR}/${RELEASE_TAG}/${SRC_TGZ_FILE}"
|
|
cp "${RELEASE_DIR}/${SRC_TGZ_FILE}.asc" "${SVN_STAGING_DIR}/${RELEASE_TAG}/${SRC_TGZ_FILE}.asc"
|
|
cp "${RELEASE_DIR}/${SRC_TGZ_FILE}.sha512" "${SVN_STAGING_DIR}/${RELEASE_TAG}/${SRC_TGZ_FILE}.sha512"
|
|
cp "${RELEASE_DIR}/${BIN_TGZ_FILE}" "${SVN_STAGING_DIR}/${RELEASE_TAG}/${BIN_TGZ_FILE}"
|
|
cp "${RELEASE_DIR}/${BIN_TGZ_FILE}.asc" "${SVN_STAGING_DIR}/${RELEASE_TAG}/${BIN_TGZ_FILE}.asc"
|
|
cp "${RELEASE_DIR}/${BIN_TGZ_FILE}.sha512" "${SVN_STAGING_DIR}/${RELEASE_TAG}/${BIN_TGZ_FILE}.sha512"
|
|
|
|
svn add "${SVN_STAGING_DIR}/${RELEASE_TAG}"
|
|
|
|
echo "Uploading release tarballs to ${SVN_STAGING_DIR}/${RELEASE_TAG}"
|
|
(
|
|
cd "${SVN_STAGING_DIR}" && \
|
|
svn commit --username "${ASF_USERNAME}" --password "${ASF_PASSWORD}" --message "Apache Celeborn ${RELEASE_TAG}"
|
|
)
|
|
echo "Celeborn tarballs uploaded"
|
|
}
|
|
|
|
upload_nexus_staging() {
|
|
echo "Deploying celeborn-client-spark-2-shaded_2.11"
|
|
${PROJECT_DIR}/build/mvn clean install -DskipTests -Papache-release,spark-2.4 \
|
|
-s "${PROJECT_DIR}/build/release/asf-settings.xml" \
|
|
-pl :celeborn-client-spark-2-shaded_2.11 -am
|
|
${PROJECT_DIR}/build/mvn deploy -DskipTests -Papache-release,spark-2.4 \
|
|
-s "${PROJECT_DIR}/build/release/asf-settings.xml" \
|
|
-pl :celeborn-client-spark-2-shaded_2.11
|
|
|
|
echo "Deploying celeborn-client-spark-3-shaded_2.12"
|
|
${PROJECT_DIR}/build/mvn clean install -DskipTests -Papache-release,spark-3.3 \
|
|
-s "${PROJECT_DIR}/build/release/asf-settings.xml" \
|
|
-pl :celeborn-client-spark-3-shaded_2.12 -am
|
|
${PROJECT_DIR}/build/mvn deploy -DskipTests -Papache-release,spark-3.3 \
|
|
-s "${PROJECT_DIR}/build/release/asf-settings.xml" \
|
|
-pl :celeborn-client-spark-3-shaded_2.12
|
|
|
|
echo "Deploying celeborn-client-flink-1.14-shaded_2.12"
|
|
${PROJECT_DIR}/build/mvn clean install -DskipTests -Papache-release,flink-1.14 \
|
|
-s "${PROJECT_DIR}/build/release/asf-settings.xml" \
|
|
-pl :celeborn-client-flink-1.14-shaded_2.12 -am
|
|
${PROJECT_DIR}/build/mvn deploy -DskipTests -Papache-release,flink-1.14 \
|
|
-s "${PROJECT_DIR}/build/release/asf-settings.xml" \
|
|
-pl :celeborn-client-flink-1.14-shaded_2.12
|
|
|
|
echo "Deploying celeborn-client-flink-1.15-shaded_2.12"
|
|
${PROJECT_DIR}/build/mvn clean install -DskipTests -Papache-release,flink-1.15 \
|
|
-s "${PROJECT_DIR}/build/release/asf-settings.xml" \
|
|
-pl :celeborn-client-flink-1.15-shaded_2.12 -am
|
|
${PROJECT_DIR}/build/mvn deploy -DskipTests -Papache-release,flink-1.15 \
|
|
-s "${PROJECT_DIR}/build/release/asf-settings.xml" \
|
|
-pl :celeborn-client-flink-1.15-shaded_2.12
|
|
|
|
echo "Deploying celeborn-client-flink-1.17-shaded_2.12"
|
|
${PROJECT_DIR}/build/mvn clean install -DskipTests -Papache-release,flink-1.17 \
|
|
-s "${PROJECT_DIR}/build/release/asf-settings.xml" \
|
|
-pl :celeborn-client-flink-1.17-shaded_2.12 -am
|
|
${PROJECT_DIR}/build/mvn deploy -DskipTests -Papache-release,flink-1.17 \
|
|
-s "${PROJECT_DIR}/build/release/asf-settings.xml" \
|
|
-pl :celeborn-client-flink-1.17-shaded_2.12
|
|
|
|
echo "Deploying celeborn-client-flink-1.18-shaded_2.12"
|
|
${PROJECT_DIR}/build/mvn clean install -DskipTests -Papache-release,flink-1.18 \
|
|
-s "${PROJECT_DIR}/build/release/asf-settings.xml" \
|
|
-pl :celeborn-client-flink-1.18-shaded_2.12 -am
|
|
${PROJECT_DIR}/build/mvn deploy -DskipTests -Papache-release,flink-1.18 \
|
|
-s "${PROJECT_DIR}/build/release/asf-settings.xml" \
|
|
-pl :celeborn-client-flink-1.18-shaded_2.12
|
|
}
|
|
|
|
finalize_svn() {
|
|
echo "Moving Celeborn tarballs to the release directory"
|
|
svn mv --username "${ASF_USERNAME}" --password "${ASF_PASSWORD}" --no-auth-cache \
|
|
--message "Apache Celeborn ${RELEASE_VERSION}" \
|
|
"${SVN_STAGING_REPO}/${RELEASE_TAG}" "${SVN_RELEASE_REPO}/celeborn-${RELEASE_VERSION}"
|
|
echo "Celeborn tarballs moved"
|
|
}
|
|
|
|
if [[ "$1" == "publish" ]]; then
|
|
package
|
|
upload_svn_staging
|
|
upload_nexus_staging
|
|
exit 0
|
|
fi
|
|
|
|
if [[ "$1" == "finalize" ]]; then
|
|
echo "THIS STEP IS IRREVERSIBLE! Make sure the vote has passed and you pick the right RC to finalize."
|
|
read -p "You must be a PMC member to run this step. Continue? [y/N] " ANSWER
|
|
if [ "$ANSWER" != "y" ]; then
|
|
echo "Exiting."
|
|
exit 1
|
|
fi
|
|
|
|
finalize_svn
|
|
exit 0
|
|
fi
|
|
|
|
exit_with_usage
|