Skip to content

Commit 7c569f8

Browse files
Merge remote-tracking branch 'origin/beta-releases' into ga-releases
2 parents 2be255d + 9a94a8e commit 7c569f8

File tree

381 files changed

+17895
-10248
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

381 files changed

+17895
-10248
lines changed

.evergreen/compass_package.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ if [[ "$OSTYPE" == "cygwin" ]]; then
88
fi
99

1010
echo "Creating signed release build..."
11-
npm run package-compass-nocompile $COMPASS_DISTRIBUTION
11+
npm run package-compass-nocompile
1212
npm run generate-first-party-deps-json
1313

1414
ls -la packages/compass/dist

.evergreen/connectivity-tests/Dockerfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
# "bullseye" is the debian distribution that ubuntu:20.04 is based on
2-
FROM node:18-bullseye
2+
ARG NODE_JS_VERSION=20
3+
FROM node:${NODE_JS_VERSION}-bullseye
34

45
COPY .evergreen/connectivity-tests/krb5.conf /etc/krb5.conf
56

.evergreen/connectivity-tests/run.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ MONOREPO_ROOT_DIR="$(cd $(dirname "$0")/../..; pwd)"
77
cd $MONOREPO_ROOT_DIR
88

99
echo "building connectivity tests image from ${PWD}"
10-
docker build -t devtools-connectivity-tests -f "./.evergreen/connectivity-tests/Dockerfile" .
10+
docker build -t devtools-connectivity-tests --build-arg "NODE_JS_VERSION=$NODE_JS_VERSION" -f "./.evergreen/connectivity-tests/Dockerfile" .
1111
echo "connectivity tests image built"
1212

1313
echo running connectivity tests image

.evergreen/functions.yml

Lines changed: 12 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,7 @@ variables:
4040
EVERGREEN_VERSION_ID: ${version_id}
4141
EVERGREEN_WORKDIR: ${workdir}
4242
EVERGREEN_CREATED_AT: ${created_at}
43-
# WARN: This version is behind our electron runtime, but updating it will
44-
# drop support for some older linux platforms, so we are keeping them out of
45-
# sync for now
46-
# TODO: https://jira.mongodb.org/browse/COMPASS-6915
47-
NODE_JS_VERSION: '18.19.1'
43+
NODE_JS_VERSION: '20.16.0'
4844
NPM_VERSION: '10.2.4'
4945
# secrets
5046
HADRON_METRICS_INTERCOM_APP_ID: ${metrics_intercom_app_id}
@@ -305,12 +301,13 @@ functions:
305301
shell: bash
306302
env:
307303
<<: *compass-env
304+
HADRON_DISTRIBUTION: ${compass_distribution}
308305
script: |
309306
set -e
310307
# Load environment variables
311308
eval $(.evergreen/print-compass-env.sh)
312309
# Generates and expansion file with build target metadata in packages/compass/expansions.yml
313-
npm run --workspace mongodb-compass build-info -- ${target_platform} ${target_arch} --format=yaml --flatten ${compass_distribution} --out expansions.raw.yml
310+
npm run --workspace mongodb-compass build-info -- ${target_platform} ${target_arch} --format=yaml --flatten --out expansions.raw.yml
314311
# the 'author' key conflicts with evergreen's own expansion
315312
grep -v '^author:' < packages/compass/expansions.raw.yml > packages/compass/expansions.yml
316313
- command: expansions.update
@@ -409,7 +406,7 @@ functions:
409406
<<: *compass-env
410407
DEBUG: ${debug}
411408
npm_config_loglevel: ${npm_loglevel}
412-
COMPASS_DISTRIBUTION: ${compass_distribution}
409+
HADRON_DISTRIBUTION: ${compass_distribution}
413410
script: |
414411
set -e
415412
@@ -447,7 +444,7 @@ functions:
447444
<<: *compass-env
448445
DEBUG: ${debug}
449446
npm_config_loglevel: ${npm_loglevel}
450-
COMPASS_DISTRIBUTION: ${compass_distribution}
447+
HADRON_DISTRIBUTION: ${compass_distribution}
451448
SIGNING_SERVER_HOSTNAME: ${SIGNING_SERVER_HOSTNAME}
452449
SIGNING_SERVER_PRIVATE_KEY: ${SIGNING_SERVER_PRIVATE_KEY}
453450
SIGNING_SERVER_PRIVATE_KEY_CYGPATH: ${SIGNING_SERVER_PRIVATE_KEY_CYGPATH}
@@ -589,11 +586,16 @@ functions:
589586
MONGODB_RUNNER_VERSION: ${mongodb_version|}
590587
E2E_TEST_GROUPS: ${e2e_test_groups}
591588
E2E_TEST_GROUP: ${e2e_test_group}
589+
ATLAS_LOCAL_VERSION: latest
590+
HADRON_DISTRIBUTION: compass
592591
script: |
593592
set -e
594593
# Load environment variables
595594
eval $(.evergreen/print-compass-env.sh)
596595
596+
# Start atlas local to test Atlas Search
597+
source .evergreen/start-atlas-local.sh
598+
597599
echo "Running E2E tests while collecting coverage..."
598600
599601
npm run --unsafe-perm --workspace compass-e2e-tests test-ci
@@ -614,6 +616,7 @@ functions:
614616
MONGODB_RUNNER_VERSION: ${mongodb_version|}
615617
E2E_TEST_GROUPS: ${e2e_test_groups}
616618
E2E_TEST_GROUP: ${e2e_test_group}
619+
HADRON_DISTRIBUTION: compass
617620
script: |
618621
set -e
619622
# Load environment variables
@@ -623,7 +626,6 @@ functions:
623626
624627
npm run --unsafe-perm --workspace compass-e2e-tests test-ci -- -- --test-multiple-connections
625628
626-
627629
test-packaged-app:
628630
- command: shell.exec
629631
# Fail the task if it's idle for 10 mins
@@ -946,6 +948,7 @@ functions:
946948
DEBUG: ${debug}
947949
SNYK_TOKEN: ${snyk_token}
948950
JIRA_API_TOKEN: ${jira_api_token}
951+
HADRON_DISTRIBUTION: compass
949952
script: |
950953
set -e
951954
# Load environment variables

.evergreen/print-compass-env.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,13 @@ function printCompassEnv() {
107107
printVar('DEV_VERSION_IDENTIFIER', process.env.DEV_VERSION_IDENTIFIER);
108108
printVar('EVERGREEN_REVISION', process.env.EVERGREEN_REVISION);
109109
printVar('EVERGREEN_REVISION_ORDER_ID', process.env.EVERGREEN_REVISION_ORDER_ID);
110+
111+
if (process.platform === 'darwin') {
112+
// Without this, kerberos 2.1.1 is broken on macOS, but this flag is only
113+
// really relevant for Linux.
114+
// https://jira.mongodb.org/browse/NODE-6320
115+
printVar('GYP_DEFINES', 'kerberos_use_rtld=false');
116+
}
110117
}
111118

112119
printCompassEnv();

.evergreen/start-atlas-local.sh

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
#!/bin/bash
2+
3+
# Check if ATLAS_LOCAL_VERSION is set
4+
if [ -z "$ATLAS_LOCAL_VERSION" ]; then
5+
echo "ATLAS_LOCAL_VERSION is not set. Skipping script."
6+
return
7+
fi
8+
9+
# Container name
10+
CONTAINER_NAME=compass-e2e-tests-atlas-local
11+
12+
docker rm -f $CONTAINER_NAME || true
13+
14+
cleanup() {
15+
echo "Stopping and removing container..."
16+
docker stop $CONTAINER_NAME || true
17+
docker rm -f $CONTAINER_NAME || true
18+
}
19+
20+
trap cleanup EXIT
21+
22+
# Image name with version
23+
IMAGE_NAME="mongodb/mongodb-atlas-local:$ATLAS_LOCAL_VERSION"
24+
echo docker run --rm --name $CONTAINER_NAME -d -e DO_NOT_TRACK=1 -P "$IMAGE_NAME"
25+
26+
# Start the Docker container
27+
docker run --rm --name $CONTAINER_NAME -d -e DO_NOT_TRACK=1 -P "$IMAGE_NAME"
28+
29+
echo "Waiting for container to become healthy..."
30+
31+
STATUS=""
32+
CONSECUTIVE_FAILED_ATTEMPTS=0
33+
MAX_CONSECUTIVE_FAILED_ATTEMPTS=20
34+
35+
while true; do
36+
INSPECT_OUTPUT=$(docker inspect --format='{{.State.Health.Status}}' $CONTAINER_NAME 2>&1)
37+
if [[ $? -ne 0 ]]; then
38+
echo "Inspect Failed: ${INSPECT_OUTPUT}"
39+
STATUS="failed"
40+
else
41+
STATUS="$INSPECT_OUTPUT"
42+
fi
43+
44+
echo "Status: $STATUS"
45+
46+
if [[ "$STATUS" != "starting" && "$STATUS" != "failed" ]]; then
47+
break
48+
fi
49+
50+
if [[ "$STATUS" == "failed" ]]; then
51+
CONSECUTIVE_FAILED_ATTEMPTS=$((CONSECUTIVE_FAILED_ATTEMPTS + 1))
52+
else
53+
CONSECUTIVE_FAILED_ATTEMPTS=0
54+
fi
55+
56+
if [[ $CONSECUTIVE_FAILED_ATTEMPTS -ge $MAX_CONSECUTIVE_FAILED_ATTEMPTS ]]; then
57+
echo "Maximum number of consecutive failed attempts reached. Exiting."
58+
exit 1
59+
fi
60+
61+
sleep 2
62+
done
63+
64+
if [[ "$STATUS" != "healthy" ]]; then
65+
echo "Atlas Local is not healthy, exiting."
66+
exit 1
67+
fi
68+
69+
EXPOSED_PORT=$(docker inspect --format='{{ (index (index .NetworkSettings.Ports "27017/tcp") 0).HostPort }}' $CONTAINER_NAME)
70+
71+
export ATLAS_LOCAL_URL="mongodb://127.0.0.1:$EXPOSED_PORT/test?directConnection=true"
72+
echo "ATLAS_LOCAL_URL set to $ATLAS_LOCAL_URL"

.github/workflows/authors-and-third-party-notices.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525

2626
- uses: actions/setup-node@v3
2727
with:
28-
node-version: 18.19.1
28+
node-version: 20.16.0
2929
cache: 'npm'
3030

3131
- name: Install [email protected]

.github/workflows/bump-packages.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ jobs:
2626
2727
- uses: actions/setup-node@v3
2828
with:
29-
node-version: 18.19.1
29+
node-version: 20.16.0
3030
cache: 'npm'
3131

3232
- name: Install [email protected]

.github/workflows/publish-compass.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
- name: Setup Node.js Environment
2323
uses: actions/setup-node@v3
2424
with:
25-
node-version: 18.19.1
25+
node-version: 20.16.0
2626
cache: 'npm'
2727

2828
- name: Install [email protected]

.github/workflows/publish-packages.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434
- name: "Use Node.js 14"
3535
uses: actions/setup-node@v3
3636
with:
37-
node-version: 18.19.1
37+
node-version: 20.16.0
3838

3939
- name: Install [email protected]
4040
run: npm install -g [email protected]

0 commit comments

Comments
 (0)