Skip to content

Commit 77bfd99

Browse files
RUBY-3726 Use new toolchain (mongodb#2958)
--------- Co-authored-by: Dmitry Rybakov <[email protected]>
1 parent ee03e8f commit 77bfd99

20 files changed

+249
-127
lines changed

.evergreen/config.yml

Lines changed: 44 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,25 @@ functions:
168168
169169
EOT
170170
171+
"run CSOT tests":
172+
- command: shell.exec
173+
type: test
174+
params:
175+
shell: bash
176+
working_dir: "src"
177+
script: |
178+
${PREPARE_SHELL}
179+
# Needed for generating temporary aws credentials.
180+
if [ -n "${FLE}" ];
181+
then
182+
export AWS_ACCESS_KEY_ID="${fle_aws_key}"
183+
export AWS_SECRET_ACCESS_KEY="${fle_aws_secret}"
184+
export AWS_DEFAULT_REGION="${fle_aws_region}"
185+
fi
186+
export CSOT_SPEC_TESTS=1
187+
TEST_CMD="bundle exec rspec spec/spec_tests/client_side_operations_timeout_spec.rb --format Rfc::Riff --format RspecJunitFormatter --out tmp/rspec.xml" \
188+
.evergreen/run-tests.sh
189+
171190
"export FLE credentials":
172191
- command: shell.exec
173192
type: test
@@ -327,7 +346,7 @@ functions:
327346
"upload test results":
328347
- command: attach.xunit_results
329348
params:
330-
file: ./src/tmp/rspec.xml
349+
file: ./src/tmp/*.xml
331350

332351
"delete private environment":
333352
- command: shell.exec
@@ -463,7 +482,7 @@ post:
463482
# Removed, causing timeouts
464483
# - func: "upload working dir"
465484
- func: "upload mo artifacts"
466-
#- func: "upload test results"
485+
- func: "upload test results"
467486
- func: "upload test results to s3"
468487

469488
task_groups:
@@ -833,11 +852,10 @@ axes:
833852
- id: "mongodb-version"
834853
display_name: MongoDB Version
835854
values:
836-
- id: "latest"
837-
display_name: "latest"
855+
- id: "8.0"
856+
display_name: "8.0"
838857
variables:
839-
MONGODB_VERSION: "latest"
840-
CRYPT_SHARED_VERSION: "latest"
858+
MONGODB_VERSION: "8.0"
841859
- id: "7.0"
842860
display_name: "7.0"
843861
variables:
@@ -1119,7 +1137,7 @@ axes:
11191137
values:
11201138
- id: mmapv1
11211139
display_name: MMAPv1
1122-
run_on: ubuntu1804-small
1140+
run_on: ubuntu2004-small
11231141
variables:
11241142
MMAPV1: 'true'
11251143

@@ -1233,8 +1251,8 @@ buildvariants:
12331251
- matrix_name: "auth/ssl"
12341252
matrix_spec:
12351253
auth-and-ssl: ["auth-and-ssl", "noauth-and-nossl"]
1236-
ruby: "ruby-3.2"
1237-
mongodb-version: ["7.0", "6.0"]
1254+
ruby: "ruby-3.3"
1255+
mongodb-version: ["8.0", "7.0"]
12381256
topology: ["standalone", "replica-set", "sharded-cluster"]
12391257
os: ubuntu2204
12401258
display_name: ${auth-and-ssl} ${ruby} db-${mongodb-version} ${topology}
@@ -1243,8 +1261,8 @@ buildvariants:
12431261

12441262
- matrix_name: "mongo-recent"
12451263
matrix_spec:
1246-
ruby: ["ruby-3.2", "ruby-3.1", "jruby-9.4"]
1247-
mongodb-version: ["7.0", "6.0"]
1264+
ruby: ["ruby-3.3", "ruby-3.2", "jruby-9.4"]
1265+
mongodb-version: ["8.0", "7.0"]
12481266
topology: ["standalone", "replica-set", "sharded-cluster"]
12491267
os: ubuntu2204
12501268
display_name: "${mongodb-version} ${os} ${topology} ${ruby}"
@@ -1263,28 +1281,18 @@ buildvariants:
12631281

12641282
- matrix_name: "mongo-5.x"
12651283
matrix_spec:
1266-
ruby: ["ruby-3.2", "ruby-2.7", "jruby-9.4"]
1267-
mongodb-version: '5.0'
1284+
ruby: ["ruby-3.3", "ruby-3.2"]
1285+
mongodb-version: ['5.0']
12681286
topology: ["standalone", "replica-set", "sharded-cluster"]
1269-
os: ubuntu1804
1270-
display_name: "${mongodb-version} ${topology} ${ruby}"
1287+
os: ubuntu2004
1288+
display_name: "${mongodb-version} ${topology} ${auth-and-ssl} ${ruby}"
12711289
tasks:
12721290
- name: "test-mlaunch"
12731291

12741292
- matrix_name: "mongo-4.x"
12751293
matrix_spec:
12761294
ruby: ["ruby-3.0", "ruby-2.7"]
1277-
mongodb-version: ['4.4', '4.2', '4.0']
1278-
topology: ["standalone", "replica-set", "sharded-cluster"]
1279-
os: ubuntu1804
1280-
display_name: "${mongodb-version} ${topology} ${ruby}"
1281-
tasks:
1282-
- name: "test-mlaunch"
1283-
1284-
- matrix_name: "mongo-3.6"
1285-
matrix_spec:
1286-
ruby: "ruby-2.7"
1287-
mongodb-version: ['3.6']
1295+
mongodb-version: ['4.4', '4.2']
12881296
topology: ["standalone", "replica-set", "sharded-cluster"]
12891297
os: ubuntu1804
12901298
display_name: "${mongodb-version} ${topology} ${ruby}"
@@ -1346,17 +1354,6 @@ buildvariants:
13461354
tasks:
13471355
- name: "test-mlaunch"
13481356

1349-
- matrix_name: mmapv1
1350-
matrix_spec:
1351-
ruby: "ruby-2.7"
1352-
mongodb-version: ['3.6', '4.0']
1353-
topology: ["standalone", "replica-set", "sharded-cluster"]
1354-
storage-engine: mmapv1
1355-
os: ubuntu1804
1356-
display_name: "${mongodb-version} ${topology} mmapv1 ${ruby}"
1357-
tasks:
1358-
- name: "test-mlaunch"
1359-
13601357
- matrix_name: "lint"
13611358
matrix_spec:
13621359
lint: on
@@ -1393,8 +1390,8 @@ buildvariants:
13931390
- matrix_name: "stress older"
13941391
matrix_spec:
13951392
stress: on
1396-
ruby: ["ruby-2.7"]
1397-
mongodb-version: ['4.2', '4.0', '3.6']
1393+
ruby: "ruby-2.7"
1394+
mongodb-version: ['4.4', '4.2']
13981395
topology: replica-set
13991396
os: ubuntu1804
14001397
display_name: "${mongodb-version} ${topology} stress ${ruby}"
@@ -1763,10 +1760,11 @@ buildvariants:
17631760
tasks:
17641761
- name: testatlas_task_group
17651762

1766-
- matrix_name: "aws-lambda"
1767-
matrix_spec:
1768-
ruby: 'ruby-3.2'
1769-
os: ubuntu2204
1770-
display_name: "AWS Lambda"
1771-
tasks:
1772-
- name: test_aws_lambda_task_group
1763+
# https://jira.mongodb.org/browse/RUBY-3311
1764+
# - matrix_name: "aws-lambda"
1765+
# matrix_spec:
1766+
# ruby: 'ruby-3.2'
1767+
# os: ubuntu2204
1768+
# display_name: "AWS Lambda"
1769+
# tasks:
1770+
# - name: test_aws_lambda_task_group

.evergreen/config/axes.yml.erb

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,10 @@ axes:
1313
- id: "mongodb-version"
1414
display_name: MongoDB Version
1515
values:
16-
- id: "latest"
17-
display_name: "latest"
16+
- id: "8.0"
17+
display_name: "8.0"
1818
variables:
19-
MONGODB_VERSION: "latest"
20-
CRYPT_SHARED_VERSION: "latest"
19+
MONGODB_VERSION: "8.0"
2120
- id: "7.0"
2221
display_name: "7.0"
2322
variables:
@@ -297,7 +296,7 @@ axes:
297296
values:
298297
- id: mmapv1
299298
display_name: MMAPv1
300-
run_on: ubuntu1804-small
299+
run_on: ubuntu2004-small
301300
variables:
302301
MMAPV1: 'true'
303302

.evergreen/config/common.yml.erb

Lines changed: 21 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,25 @@ functions:
165165

166166
EOT
167167

168+
"run CSOT tests":
169+
- command: shell.exec
170+
type: test
171+
params:
172+
shell: bash
173+
working_dir: "src"
174+
script: |
175+
${PREPARE_SHELL}
176+
# Needed for generating temporary aws credentials.
177+
if [ -n "${FLE}" ];
178+
then
179+
export AWS_ACCESS_KEY_ID="${fle_aws_key}"
180+
export AWS_SECRET_ACCESS_KEY="${fle_aws_secret}"
181+
export AWS_DEFAULT_REGION="${fle_aws_region}"
182+
fi
183+
export CSOT_SPEC_TESTS=1
184+
TEST_CMD="bundle exec rspec spec/spec_tests/client_side_operations_timeout_spec.rb --format Rfc::Riff --format RspecJunitFormatter --out tmp/rspec.xml" \
185+
.evergreen/run-tests.sh
186+
168187
"export FLE credentials":
169188
- command: shell.exec
170189
type: test
@@ -324,7 +343,7 @@ functions:
324343
"upload test results":
325344
- command: attach.xunit_results
326345
params:
327-
file: ./src/tmp/rspec.xml
346+
file: ./src/tmp/*.xml
328347

329348
"delete private environment":
330349
- command: shell.exec
@@ -460,7 +479,7 @@ post:
460479
# Removed, causing timeouts
461480
# - func: "upload working dir"
462481
- func: "upload mo artifacts"
463-
#- func: "upload test results"
482+
- func: "upload test results"
464483
- func: "upload test results to s3"
465484

466485
task_groups:

.evergreen/config/standard.yml.erb

Lines changed: 22 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,10 @@
88
# these are used for testing against a few recent ruby versions
99
recent_rubies = %w( ruby-3.2 ruby-3.1 jruby-9.4 )
1010

11-
# this is a list of the most most recent 3.x and 2.x MRI ruby versions
12-
sample_mri_rubies = %w( ruby-3.2 ruby-2.7 )
11+
recent_mri_rubies = %w( ruby-3.3 ruby-3.2 )
12+
13+
# this is a list of the most recent 3.x and 2.x MRI ruby versions
14+
sample_mri_rubies = %w( ruby-3.3 ruby-2.7 )
1315

1416
# as above, but including the most recent JRuby release
1517
sample_rubies = sample_mri_rubies + %w( jruby-9.4 )
@@ -28,11 +30,8 @@
2830
# The latest stable version of MongoDB
2931
latest_stable_mdb = "7.0".inspect # so it gets quoted as a string
3032

31-
# A few of the most recent MongoDB versions
32-
actual_and_upcoming_mdb = %w( 7.0 6.0 )
3333

34-
recent_mdb = %w( 6.0 5.0 )
35-
latest_5x_mdb = "5.0".inspect # so it gets quoted as a string
34+
recent_mdb = %w( 8.0 7.0 )
3635
%>
3736

3837
buildvariants:
@@ -50,7 +49,7 @@ buildvariants:
5049
matrix_spec:
5150
auth-and-ssl: ["auth-and-ssl", "noauth-and-nossl"]
5251
ruby: <%= latest_ruby %>
53-
mongodb-version: <%= actual_and_upcoming_mdb %>
52+
mongodb-version: <%= recent_mdb %>
5453
topology: <%= topologies %>
5554
os: ubuntu2204
5655
display_name: ${auth-and-ssl} ${ruby} db-${mongodb-version} ${topology}
@@ -60,7 +59,7 @@ buildvariants:
6059
- matrix_name: "mongo-recent"
6160
matrix_spec:
6261
ruby: <%= recent_rubies %>
63-
mongodb-version: <%= actual_and_upcoming_mdb %>
62+
mongodb-version: <%= recent_mdb %>
6463
topology: <%= topologies %>
6564
os: ubuntu2204
6665
display_name: "${mongodb-version} ${os} ${topology} ${ruby}"
@@ -79,28 +78,18 @@ buildvariants:
7978

8079
- matrix_name: "mongo-5.x"
8180
matrix_spec:
82-
ruby: <%= sample_rubies %>
83-
mongodb-version: '5.0'
81+
ruby: <%= recent_mri_rubies %>
82+
mongodb-version: ['5.0']
8483
topology: <%= topologies %>
85-
os: ubuntu1804
86-
display_name: "${mongodb-version} ${topology} ${ruby}"
84+
os: ubuntu2004
85+
display_name: "${mongodb-version} ${topology} ${auth-and-ssl} ${ruby}"
8786
tasks:
8887
- name: "test-mlaunch"
8988

9089
- matrix_name: "mongo-4.x"
9190
matrix_spec:
9291
ruby: <%= older_rubies %>
93-
mongodb-version: ['4.4', '4.2', '4.0']
94-
topology: <%= topologies %>
95-
os: ubuntu1804
96-
display_name: "${mongodb-version} ${topology} ${ruby}"
97-
tasks:
98-
- name: "test-mlaunch"
99-
100-
- matrix_name: "mongo-3.6"
101-
matrix_spec:
102-
ruby: "ruby-2.7"
103-
mongodb-version: ['3.6']
92+
mongodb-version: ['4.4', '4.2']
10493
topology: <%= topologies %>
10594
os: ubuntu1804
10695
display_name: "${mongodb-version} ${topology} ${ruby}"
@@ -162,17 +151,6 @@ buildvariants:
162151
tasks:
163152
- name: "test-mlaunch"
164153

165-
- matrix_name: mmapv1
166-
matrix_spec:
167-
ruby: "ruby-2.7"
168-
mongodb-version: ['3.6', '4.0']
169-
topology: <%= topologies %>
170-
storage-engine: mmapv1
171-
os: ubuntu1804
172-
display_name: "${mongodb-version} ${topology} mmapv1 ${ruby}"
173-
tasks:
174-
- name: "test-mlaunch"
175-
176154
- matrix_name: "lint"
177155
matrix_spec:
178156
lint: on
@@ -209,8 +187,8 @@ buildvariants:
209187
- matrix_name: "stress older"
210188
matrix_spec:
211189
stress: on
212-
ruby: ["ruby-2.7"]
213-
mongodb-version: ['4.2', '4.0', '3.6']
190+
ruby: <%= supported_mri_ruby_2 %>
191+
mongodb-version: ['4.4', '4.2']
214192
topology: replica-set
215193
os: ubuntu1804
216194
display_name: "${mongodb-version} ${topology} stress ${ruby}"
@@ -482,10 +460,11 @@ buildvariants:
482460
tasks:
483461
- name: testatlas_task_group
484462

485-
- matrix_name: "aws-lambda"
486-
matrix_spec:
487-
ruby: 'ruby-3.2'
488-
os: ubuntu2204
489-
display_name: "AWS Lambda"
490-
tasks:
491-
- name: test_aws_lambda_task_group
463+
# https://jira.mongodb.org/browse/RUBY-3311
464+
# - matrix_name: "aws-lambda"
465+
# matrix_spec:
466+
# ruby: 'ruby-3.2'
467+
# os: ubuntu2204
468+
# display_name: "AWS Lambda"
469+
# tasks:
470+
# - name: test_aws_lambda_task_group

.evergreen/run-tests-atlas-full.sh

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,27 @@ set -ex
88

99
set_env_vars
1010
set_env_python
11-
set_env_ruby
11+
12+
# Install rbenv and download the requested ruby version
13+
rm -rf ~/.rbenv
14+
git clone https://github.com/rbenv/rbenv.git ~/.rbenv
15+
rm -rf ~/.rbenv/versions/
16+
curl --retry 3 -fL http://boxes.10gen.com/build/toolchain-drivers/mongo-ruby-toolchain/library/`host_distro`/$RVM_RUBY.tar.xz |tar -xC $HOME/.rbenv/ -Jf -
17+
export PATH="$HOME/.rbenv/bin:$PATH"
18+
eval "$(rbenv init - bash)"
19+
export FULL_RUBY_VERSION=$(ls ~/.rbenv/versions | head -n1)
20+
rbenv global $FULL_RUBY_VERSION
21+
22+
export JAVA_HOME=/opt/java/jdk21
23+
export JAVACMD=$JAVA_HOME/bin/java
1224

1325
bundle_install
1426

1527
ATLAS_URI=$MONGODB_URI \
1628
SERVERLESS=1 \
1729
EXAMPLE_TIMEOUT=600 \
18-
bundle exec rspec -fd spec/integration/search_indexes_prose_spec.rb
30+
bundle exec rspec -fd spec/integration/search_indexes_prose_spec.rb \
31+
--format Rfc::Riff --format RspecJunitFormatter --out tmp/rspec.xml
1932

2033
test_status=$?
2134

0 commit comments

Comments
 (0)