This is an automated email from the ASF dual-hosted git repository.

adoroszlai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ratis.git


The following commit(s) were added to refs/heads/master by this push:
     new d75e6f3fb RATIS-1935. Remove yetus related code. (#965)
d75e6f3fb is described below

commit d75e6f3fbb208d05932e601deecc0e308ae78708
Author: Tsz-Wo Nicholas Sze <[email protected]>
AuthorDate: Tue Nov 14 12:02:09 2023 -0800

    RATIS-1935. Remove yetus related code. (#965)
---
 dev-support/ci/README.md          |  40 ---------
 dev-support/ci/common.sh          |  38 --------
 dev-support/ci/nightly-build.sh   |  47 ----------
 dev-support/ci/precommit-build.sh |  49 -----------
 dev-support/test-patch            |  18 ----
 dev-support/yetus-personality.sh  |  46 ----------
 dev-support/yetus-wrapper         | 178 --------------------------------------
 ratis-proto/pom.xml               |  15 ----
 8 files changed, 431 deletions(-)

diff --git a/dev-support/ci/README.md b/dev-support/ci/README.md
deleted file mode 100644
index b306e7f4a..000000000
--- a/dev-support/ci/README.md
+++ /dev/null
@@ -1,40 +0,0 @@
-<!--
-  Licensed 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. See accompanying LICENSE file.
--->
-
-RATIS CI scripts
-----------------
-
-These scripts are called from jenkins for ratis pre-commit and nightly build 
jobs.
-
-On jenkins, the repository is checked out to a subdirectory (sourcedir) and 
the script is called from the parent directory which is also used to store 
temporary files (yetus/out/...).
-
-IT'S NOT RECOMMENDED to run it locally unless you know what could be expected. 
The script runs in sentinel/robot mode, so:
-
- * Old docker images are removed by the script
- * Local commits are removed by the script
-
-
-## Running locally
-
-To test the jenkins build locally:
-
- 1. create a new directory
- 2. Clone the ratis repository to a subdirectory: `git clone 
git://github.com/apache/ratis.git sourcedir`
- 3. Run the script fro the parent directory 
./sourcedir/dev-support/ci/nightly-build.sh
-
-For nightly-build.sh you can set the BRANCH environment variable to define 
which branch should be tested.
-
-For precommit-build.sh you should set ISSUE_NUM (eg. 122, RATIS prefix should 
not be added).
-
-The variables are set by the jenkins.
diff --git a/dev-support/ci/common.sh b/dev-support/ci/common.sh
deleted file mode 100644
index a786524b8..000000000
--- a/dev-support/ci/common.sh
+++ /dev/null
@@ -1,38 +0,0 @@
-#!/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.
-
-DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-
-#Workspace is set by the jenkins, by default (local run) is the parent 
directory of the checkout.
-WORKSPACE=${WORKSPACE:-$DIR/../../..}
-cd $WORKSPACE
-
-YETUSDIR=${WORKSPACE}/yetus
-TESTPATCHBIN=${YETUSDIR}/bin/test-patch
-ARTIFACTS=${WORKSPACE}/out
-BASEDIR=${WORKSPACE}/sourcedir
-TOOLS=${WORKSPACE}/tools
-rm -rf "${ARTIFACTS}" "${YETUSDIR}"
-mkdir -p "${ARTIFACTS}" "${YETUSDIR}" "${TOOLS}"
-
-#It's not on all the branches, so we need to copy it from the checkout out 
source
-cp $BASEDIR/dev-support/yetus-personality.sh $WORKSPACE/
-cp $BASEDIR/dev-support/docker/Dockerfile $WORKSPACE/
-
-YETUS_VERSION=${YETUS_VERSION:-0.8.0}
-echo "Downloading Yetus"
-curl -L 
https://archive.apache.org/dist/yetus/${YETUS_VERSION}/yetus-${YETUS_VERSION}-bin.tar.gz
 -o yetus.tar.gz
-gunzip -c yetus.tar.gz | tar xpf - -C "${YETUSDIR}" --strip-components 1
diff --git a/dev-support/ci/nightly-build.sh b/dev-support/ci/nightly-build.sh
deleted file mode 100644
index ff11058c3..000000000
--- a/dev-support/ci/nightly-build.sh
+++ /dev/null
@@ -1,47 +0,0 @@
-#!/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.
-
-DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-source $DIR/common.sh
-
-YETUS_ARGS+=("--archive-list=checkstyle-errors.xml,findbugsXml.xml")
-YETUS_ARGS+=("--basedir=${BASEDIR}")
-YETUS_ARGS+=("--branch=${BRANCH:-master}")
-YETUS_ARGS+=("--brief-report-file=${ARTIFACTS}/email-report.txt")
-YETUS_ARGS+=("--build-url-artifacts=artifact/out")
-YETUS_ARGS+=("--console-report-file=${ARTIFACTS}/console-report.txt")
-YETUS_ARGS+=("--console-urls")
-YETUS_ARGS+=("--docker")
-YETUS_ARGS+=("--dockerfile=${WORKSPACE}/Dockerfile")
-YETUS_ARGS+=("--dockermemlimit=20g")
-YETUS_ARGS+=("--empty-patch")
-YETUS_ARGS+=("--html-report-file=${ARTIFACTS}/console-report.html")
-YETUS_ARGS+=("--java-home=/usr/lib/jvm/java-8-openjdk-amd64")
-YETUS_ARGS+=("--jenkins")
-YETUS_ARGS+=("--mvn-custom-repos")
-YETUS_ARGS+=("--patch-dir=${ARTIFACTS}")
-YETUS_ARGS+=("--plugins=all,-author")
-YETUS_ARGS+=("--proclimit=5000")
-YETUS_ARGS+=("--project=ratis")
-YETUS_ARGS+=("--personality=${WORKSPACE}/yetus-personality.sh")
-YETUS_ARGS+=("--resetrepo")
-YETUS_ARGS+=("--sentinel")
-YETUS_ARGS+=("--shelldocs=/testptch/hadoop/dev-support/bin/shelldocs")
-YETUS_ARGS+=("--tests-filter=cc,checkstyle,javac,javadoc,pylint,shellcheck,shelldocs,whitespace")
-
-TESTPATCHBIN=${YETUSDIR}/bin/test-patch
-
-/bin/bash ${TESTPATCHBIN} "${YETUS_ARGS[@]}"
diff --git a/dev-support/ci/precommit-build.sh 
b/dev-support/ci/precommit-build.sh
deleted file mode 100644
index 7cae44f7e..000000000
--- a/dev-support/ci/precommit-build.sh
+++ /dev/null
@@ -1,49 +0,0 @@
-#!/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.
-
-DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
-source $DIR/common.sh
-
-YETUS_ARGS+=("--archive-list=checkstyle-errors.xml,findbugsXml.xml")
-YETUS_ARGS+=("--basedir=${BASEDIR}")
-YETUS_ARGS+=("--brief-report-file=${ARTIFACTS}/email-report.txt")
-YETUS_ARGS+=("--build-url-artifacts=artifact/out")
-YETUS_ARGS+=("--console-report-file=${ARTIFACTS}/console-report.txt")
-YETUS_ARGS+=("--console-urls")
-YETUS_ARGS+=("--docker")
-YETUS_ARGS+=("--dockerfile=${WORKSPACE}/Dockerfile")
-YETUS_ARGS+=("--dockermemlimit=20g")
-YETUS_ARGS+=("--findbugs-strict-precheck")
-YETUS_ARGS+=("--html-report-file=${ARTIFACTS}/console-report.html")
-YETUS_ARGS+=("--jenkins")
-YETUS_ARGS+=("--jira-password=${JIRA_PASSWORD}")
-YETUS_ARGS+=("--jira-user=hadoopqa")
-YETUS_ARGS+=("--multijdkdirs=/usr/lib/jvm/java-8-oracle")
-YETUS_ARGS+=("--mvn-custom-repos")
-YETUS_ARGS+=("--patch-dir=${ARTIFACTS}")
-YETUS_ARGS+=("--project=ratis")
-YETUS_ARGS+=("--personality=${WORKSPACE}/yetus-personality.sh")
-YETUS_ARGS+=("--proclimit=5000")
-YETUS_ARGS+=("--resetrepo")
-YETUS_ARGS+=("--sentinel")
-YETUS_ARGS+=("--shelldocs=/testptch/hadoop/dev-support/bin/shelldocs")
-YETUS_ARGS+=("--skip-dir=dev-support")
-YETUS_ARGS+=("--tests-filter=checkstyle,pylint,shelldocs")
-
-YETUS_ARGS+=("RATIS-${ISSUE_NUM}")
-
-
-/bin/bash ${TESTPATCHBIN} "${YETUS_ARGS[@]}"
diff --git a/dev-support/test-patch b/dev-support/test-patch
deleted file mode 100644
index 25d9d81ef..000000000
--- a/dev-support/test-patch
+++ /dev/null
@@ -1,18 +0,0 @@
-#!/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.
-
-BINDIR=$(cd -P -- "$(dirname -- "${BASH_SOURCE-0}")" >/dev/null && pwd -P)
-exec "${BINDIR}/yetus-wrapper" test-patch --project=ratis 
--dockerfile="$BINDIR/docker/Dockerfile" 
--personality=$BINDIR/yetus-personality.sh --skip-dir=dev-support "$@"
diff --git a/dev-support/yetus-personality.sh b/dev-support/yetus-personality.sh
deleted file mode 100644
index 8423219fe..000000000
--- a/dev-support/yetus-personality.sh
+++ /dev/null
@@ -1,46 +0,0 @@
-#!/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.
-
-personality_plugins "all"
-
-## @description  Globals specific to this personality
-## @audience     private
-## @stability    evolving
-function personality_globals
-{
-  # shellcheck disable=SC2034
-  BUILDTOOL=maven
-  #shellcheck disable=SC2034
-  PATCH_BRANCH_DEFAULT=master
-  #shellcheck disable=SC2034
-  JIRA_ISSUE_RE='^RATIS-[0-9]+$'
-  #shellcheck disable=SC2034
-  GITHUB_REPO="apache/ratis"
-}
-
-
-## @description  Queue up modules for this personality
-## @audience     private
-## @stability    evolving
-## @param        repostatus
-## @param        testtype
-function personality_modules
-{
-  #Ratis is not a big project, we can always run everything on the whole 
project.
-  #Especially as we need the generated sources and shaded client.
-  clear_personality_queue
-  personality_enqueue_module .
-}
diff --git a/dev-support/yetus-wrapper b/dev-support/yetus-wrapper
deleted file mode 100644
index ae05d426b..000000000
--- a/dev-support/yetus-wrapper
+++ /dev/null
@@ -1,178 +0,0 @@
-#!/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.
-
-# you must be this high to ride the ride
-if [[ -z "${BASH_VERSINFO[0]}" ]] \
-   || [[ "${BASH_VERSINFO[0]}" -lt 3 ]] \
-   || [[ "${BASH_VERSINFO[0]}" -eq 3 && "${BASH_VERSINFO[1]}" -lt 2 ]]; then
-  echo "bash v3.2+ is required. Sorry."
-  exit 1
-fi
-
-set -o pipefail
-
-## @description  Print a message to stderr
-## @audience     public
-## @stability    stable
-## @replaceable  no
-## @param        string
-function yetus_error
-{
-  echo "$*" 1>&2
-}
-
-## @description  Given a filename or dir, return the absolute version of it
-## @audience     public
-## @stability    stable
-## @param        directory
-## @replaceable  no
-## @return       0 success
-## @return       1 failure
-## @return       stdout abspath
-function yetus_abs
-{
-  declare obj=$1
-  declare dir
-  declare fn
-  declare dirret
-
-  if [[ ! -e ${obj} ]]; then
-    return 1
-  elif [[ -d ${obj} ]]; then
-    dir=${obj}
-  else
-    dir=$(dirname -- "${obj}")
-    fn=$(basename -- "${obj}")
-    fn="/${fn}"
-  fi
-
-  dir=$(cd -P -- "${dir}" >/dev/null 2>/dev/null && pwd -P)
-  dirret=$?
-  if [[ ${dirret} = 0 ]]; then
-    echo "${dir}${fn}"
-    return 0
-  fi
-  return 1
-}
-
-
-WANTED="$1"
-shift
-ARGV=("$@")
-
-HADOOP_YETUS_VERSION=${HADOOP_YETUS_VERSION:-0.8.0}
-BIN=$(yetus_abs "${BASH_SOURCE-$0}")
-BINDIR=$(dirname "${BIN}")
-
-###
-###  if YETUS_HOME is set, then try to use it
-###
-if [[ -n "${YETUS_HOME}"
-   && -x "${YETUS_HOME}/bin/${WANTED}" ]]; then
-  exec "${YETUS_HOME}/bin/${WANTED}" "${ARGV[@]}"
-fi
-
-#
-# this directory is ignored by git and maven
-#
-HADOOP_PATCHPROCESS=${HADOOP_PATCHPROCESS:-"${BINDIR}/../../patchprocess"}
-
-if [[ ! -d "${HADOOP_PATCHPROCESS}" ]]; then
-  mkdir -p "${HADOOP_PATCHPROCESS}"
-fi
-
-mytmpdir=$(yetus_abs "${HADOOP_PATCHPROCESS}")
-ret=$?
-if [[ ${ret} != 0 ]]; then
-  yetus_error "yetus-dl: Unable to cwd to ${HADOOP_PATCHPROCESS}"
-  exit 1
-fi
-HADOOP_PATCHPROCESS=${mytmpdir}
-
-##
-## if we've already DL'd it, then short cut
-##
-if [[ -x "${HADOOP_PATCHPROCESS}/yetus-${HADOOP_YETUS_VERSION}/bin/${WANTED}" 
]]; then
-  exec "${HADOOP_PATCHPROCESS}/yetus-${HADOOP_YETUS_VERSION}/bin/${WANTED}" 
"${ARGV[@]}"
-fi
-
-##
-## need to DL, etc
-##
-
-BASEURL="https://archive.apache.org/dist/yetus/${HADOOP_YETUS_VERSION}/";
-TARBALL="yetus-${HADOOP_YETUS_VERSION}-bin.tar"
-
-GPGBIN=$(command -v gpg)
-CURLBIN=$(command -v curl)
-
-if ! pushd "${HADOOP_PATCHPROCESS}" >/dev/null; then
-  yetus_error "ERROR: yetus-dl: Cannot pushd to ${HADOOP_PATCHPROCESS}"
-  exit 1
-fi
-
-if [[ -n "${CURLBIN}" ]]; then
-  if ! "${CURLBIN}" -f -s -L -O "${BASEURL}/${TARBALL}.gz"; then
-    yetus_error "ERROR: yetus-dl: unable to download ${BASEURL}/${TARBALL}.gz"
-    exit 1
-  fi
-else
-  yetus_error "ERROR: yetus-dl requires curl."
-  exit 1
-fi
-
-if [[ -n "${GPGBIN}" ]]; then
-  if ! mkdir -p .gpg; then
-    yetus_error "ERROR: yetus-dl: Unable to create ${HADOOP_PATCHPROCESS}/.gpg"
-    exit 1
-  fi
-  if ! chmod -R 700 .gpg; then
-    yetus_error "ERROR: yetus-dl: Unable to chmod ${HADOOP_PATCHPROCESS}/.gpg"
-    exit 1
-  fi
-  if ! "${CURLBIN}" -s -L -o KEYS_YETUS 
https://dist.apache.org/repos/dist/release/yetus/KEYS; then
-    yetus_error "ERROR: yetus-dl: unable to fetch 
https://dist.apache.org/repos/dist/release/yetus/KEYS";
-    exit 1
-  fi
-  if ! "${CURLBIN}" -s -L -O "${BASEURL}/${TARBALL}.gz.asc"; then
-    yetus_error "ERROR: yetus-dl: unable to fetch ${BASEURL}/${TARBALL}.gz.asc"
-    exit 1
-  fi
-  if ! "${GPGBIN}" --homedir "${HADOOP_PATCHPROCESS}/.gpg" --import 
"${HADOOP_PATCHPROCESS}/KEYS_YETUS" >/dev/null 2>&1; then
-    yetus_error "ERROR: yetus-dl: gpg unable to import 
${HADOOP_PATCHPROCESS}/KEYS_YETUS"
-    exit 1
-  fi
-  if ! "${GPGBIN}" --homedir "${HADOOP_PATCHPROCESS}/.gpg" --verify 
"${TARBALL}.gz.asc" >/dev/null 2>&1; then
-     yetus_error "ERROR: yetus-dl: gpg verify of tarball in 
${HADOOP_PATCHPROCESS} failed"
-     exit 1
-   fi
-fi
-
-if ! (gunzip -c "${TARBALL}.gz" | tar xpf -); then
-  yetus_error "ERROR: ${TARBALL}.gz is corrupt. Investigate and then remove 
${HADOOP_PATCHPROCESS} to try again."
-  exit 1
-fi
-
-if [[ -x "${HADOOP_PATCHPROCESS}/yetus-${HADOOP_YETUS_VERSION}/bin/${WANTED}" 
]]; then
-  popd >/dev/null
-  exec "${HADOOP_PATCHPROCESS}/yetus-${HADOOP_YETUS_VERSION}/bin/${WANTED}" 
"${ARGV[@]}"
-fi
-
-##
-## give up
-##
-yetus_error "ERROR: ${WANTED} is not part of Apache Yetus 
${HADOOP_YETUS_VERSION}"
-exit 1
diff --git a/ratis-proto/pom.xml b/ratis-proto/pom.xml
index 5b38917e8..cfa04094e 100644
--- a/ratis-proto/pom.xml
+++ b/ratis-proto/pom.xml
@@ -102,21 +102,6 @@
           </execution>
         </executions>
       </plugin>
-      <plugin>
-        <artifactId>maven-jar-plugin</artifactId>
-        <executions>
-          <execution>
-            <!-- Replace the "default" jar-plugin execution -->
-            <!-- This is a super-dirty hack to work around Yetus
-                 PreCommit not using the package lifecycle phase -->
-            <id>default-jar</id>
-            <phase>process-classes</phase>
-            <goals>
-              <goal>jar</goal>
-            </goals>
-          </execution>
-        </executions>
-      </plugin>
       <!-- Modify the generated source to use our shaded protobuf -->
       <plugin>
         <groupId>com.google.code.maven-replacer-plugin</groupId>

Reply via email to