Skip to content

Commit 1a30692

Browse files
authored
HBASE-26176 Correct regex in hbase-personality.sh (#3568)
This is a rework of the original commit to enable Hadoop 3 profile for the HBASE-25853 branch. Signed-off-by: Tak Lon (Stephen) Wu <[email protected]>
1 parent 4fbc4c2 commit 1a30692

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

dev-support/hbase-personality.sh

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,8 @@ function personality_modules
148148
# If we have HADOOP_PROFILE specified and we're on branch-2.x, pass along
149149
# the hadoop.profile system property. Ensures that Hadoop2 and Hadoop3
150150
# logic is not both activated within Maven.
151-
if [[ -n "${HADOOP_PROFILE}" ]] && [[ "${PATCH_BRANCH}" =~ branch-2* ]] ; then
151+
if [[ -n "${HADOOP_PROFILE}" ]] \
152+
&& { [[ "${PATCH_BRANCH}" = branch-2* ]] || [[ "${PATCH_BRANCH}" = HBASE-25853 ]]; }; then
152153
extra="${extra} -Dhadoop.profile=${HADOOP_PROFILE}"
153154
fi
154155

@@ -354,7 +355,7 @@ function refguide_filefilter
354355

355356
if [[ ${filename} =~ src/main/asciidoc ]] ||
356357
[[ ${filename} =~ src/main/xslt ]] ||
357-
[[ ${filename} =~ hbase-common/src/main/resources/hbase-default.xml ]]; then
358+
[[ ${filename} =~ hbase-common/src/main/resources/hbase-default\.xml ]]; then
358359
add_test refguide
359360
fi
360361
}
@@ -464,7 +465,8 @@ function shadedjars_rebuild
464465
# If we have HADOOP_PROFILE specified and we're on branch-2.x, pass along
465466
# the hadoop.profile system property. Ensures that Hadoop2 and Hadoop3
466467
# logic is not both activated within Maven.
467-
if [[ -n "${HADOOP_PROFILE}" ]] && [[ "${PATCH_BRANCH}" =~ branch-2* ]] ; then
468+
if [[ -n "${HADOOP_PROFILE}" ]] \
469+
&& { [[ "${PATCH_BRANCH}" = branch-2* ]] || [[ "${PATCH_BRANCH}" = HBASE-25853 ]]; }; then
468470
maven_args+=("-Dhadoop.profile=${HADOOP_PROFILE}")
469471
fi
470472

@@ -495,7 +497,7 @@ function hadoopcheck_filefilter
495497
{
496498
local filename=$1
497499

498-
if [[ ${filename} =~ \.java$ ]] || [[ ${filename} =~ pom.xml$ ]]; then
500+
if [[ ${filename} =~ \.java$ ]] || [[ ${filename} =~ pom\.xml$ ]]; then
499501
add_test hadoopcheck
500502
fi
501503
}
@@ -643,7 +645,7 @@ function hadoopcheck_rebuild
643645
done
644646

645647
hadoop_profile=""
646-
if [[ "${PATCH_BRANCH}" =~ branch-2* ]]; then
648+
if [[ "${PATCH_BRANCH}" = branch-2* ]] || [[ "${PATCH_BRANCH}" = HBASE-25853 ]]; then
647649
hadoop_profile="-Dhadoop.profile=3.0"
648650
fi
649651
for hadoopver in ${hbase_hadoop3_versions}; do

0 commit comments

Comments
 (0)