Skip to content
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

DRIVERS-3002 Add download-mongodb capabilities to mongodl #522

Merged
merged 24 commits into from
Oct 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 60 additions & 2 deletions .evergreen/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -477,6 +477,49 @@ functions:
cd ${PROJECT_DIRECTORY}
make test

"run mongodl test partial":
- command: shell.exec
type: test
params:
shell: bash
script: |-
set -o errexit
cd ${DRIVERS_TOOLS}/.evergreen
. find-python3.sh
PYTHON=$(ensure_python3)
echo "Using PYTHON: $PYTHON"
$PYTHON mongodl.py --edition enterprise --version 7.0 --component archive-debug --no-download
$PYTHON mongodl.py --edition enterprise --version 7.0 --component cryptd --test

"run mongodl test full":
- command: shell.exec
type: test
params:
shell: bash
script: |-
set -o errexit
cd ${DRIVERS_TOOLS}/.evergreen
. find-python3.sh
PYTHON=$(ensure_python3 2>/dev/null)
echo "Using PYTHON: $PYTHON"
# Ensure that all distros are accounted for in DISTRO_ID_TO_TARGET
export VALIDATE_DISTROS=1
$PYTHON mongodl.py --list
if [ "$OS" != "Windows_NT" ]; then
$PYTHON mongodl.py --edition enterprise --version 7.0.1 --component archive-debug --test
fi
$PYTHON mongodl.py --edition enterprise --version 3.6 --component archive --test
$PYTHON mongodl.py --edition enterprise --version 4.0 --component archive --test
$PYTHON mongodl.py --edition enterprise --version 4.2 --component archive --test
$PYTHON mongodl.py --edition enterprise --version 4.4 --component archive --test
$PYTHON mongodl.py --edition enterprise --version 5.0 --component archive --test
$PYTHON mongodl.py --edition enterprise --version 6.0 --component crypt_shared --test
$PYTHON mongodl.py --edition enterprise --version 8.0 --component archive --test
$PYTHON mongodl.py --edition enterprise --version rapid --component archive --test
$PYTHON mongodl.py --edition enterprise --version latest --component archive --out $(pwd)
$PYTHON mongodl.py --edition enterprise --version v6.0-perf --component cryptd --test
$PYTHON mongodl.py --edition enterprise --version v8.0-perf --component cryptd --test

"teardown assets":
- command: subprocess.exec
params:
Expand Down Expand Up @@ -926,6 +969,16 @@ tasks:
commands:
- func: "run install binaries test"

- name: "test-mongodl-full"
tags: ["pr"]
commands:
- func: "run mongodl test full"

- name: "test-mongodl-partial"
tags: ["pr"]
commands:
- func: "run mongodl test partial"

# }}}

task_groups:
Expand Down Expand Up @@ -1358,6 +1411,7 @@ buildvariants:
then:
add_tasks:
- "test-install-binaries"
- "test-mongodl-full"
- "test-8.0-standalone-require-api"

- matrix_name: "tests-os-requires-50"
Expand All @@ -1382,7 +1436,9 @@ buildvariants:
ssl: "ssl"
os-requires-50: "*"
then:
add_tasks: ["test-install-binaries"]
add_tasks:
- "test-install-binaries"
- "test-mongodl-partial"

- matrix_name: "tests-os-requires-70"
matrix_spec: {"os-requires-70": "*", auth: "*", ssl: "*" }
Expand All @@ -1403,7 +1459,9 @@ buildvariants:
ssl: "ssl"
os-requires-70: "*"
then:
add_tasks: ["test-install-binaries"]
add_tasks:
- "test-install-binaries"
- "test-mongodl-partial"

# Storage Engine Tests on Ubuntu 20.04
- matrix_name: "tests-storage-engines"
Expand Down
4 changes: 2 additions & 2 deletions .evergreen/download-mongodb.sh
Original file line number Diff line number Diff line change
Expand Up @@ -59,8 +59,8 @@ get_mongodb_download_url_for ()
VERSION_MONGOSH="2.1.1"
# Set VERSION_RAPID to the latest rapid release each quarter.
VERSION_RAPID="7.3.4"
VERSION_80="8.0.1-rc0"
VERSION_70="7.0.14"
VERSION_80="8.0.1"
VERSION_70="7.0.15-rc1"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why remove 8.0.1-rc0 but add 7.0.15-rc1? Shouldn't we either ignore rc's altogether or update them consistently?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is looking for the latest of each type, 8.0.1 went final. Perhaps we need to add a --pre flag for whether to allow prereleases?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh I misread this as going from 8.0.1-rc0 -> 8.0.0. The current behavior of automatically using rc's seems fine to me. It has the potential to make us catch issues faster.

VERSION_60="6.0.18"
VERSION_50="5.0.29"

Expand Down
11 changes: 9 additions & 2 deletions .evergreen/find-python3.sh
Original file line number Diff line number Diff line change
Expand Up @@ -52,8 +52,15 @@ is_python3() (
echo " - $bin: $version_output"

# shellcheck disable=SC2091
if ! $("$bin" -c "import sys; exit(sys.version_info[0] == 3 and sys.version_info[1] == 12)"); then
echo "Detected Python 3.12. Skipping due to failures to start mock KMS server. Refer: DRIVERS-2743"
if ! $("$bin" -c "import sys; exit(sys.version_info[0] == 3 and sys.version_info[1] >= 12)"); then
echo "Detected Python 3.12+. Skipping due to failures to start mock KMS server. Refer: DRIVERS-2743"
return 1
fi

# shellcheck disable=SC2091
if ! $("$bin" -c "import sys; exit(sys.version_info[0] == 3 and sys.version_info[1] < 8)"); then
version=$($bin --version)
echo "Detected EOL Python ${version}, skipping."
return 1
fi

Expand Down
Loading
Loading