@@ -283,6 +283,17 @@ functions:
283
283
add_expansions_to_env : true
284
284
script : mongo-cxx-driver/.evergreen/install_c_driver.sh
285
285
286
+ # This function may be used to fetch CI scripts in the C driver
287
+ " fetch_c_driver_source " :
288
+ - command : shell.exec
289
+ params :
290
+ shell : bash
291
+ working_dir : " ."
292
+ script : |
293
+ set -o errexit
294
+ set -o pipefail
295
+ git clone --depth 1 https://github.com/mongodb/mongo-c-driver mongoc
296
+
286
297
" lint " :
287
298
- command : shell.exec
288
299
params :
@@ -832,45 +843,48 @@ tasks:
832
843
- name : clang-tidy
833
844
commands :
834
845
- func : " setup"
835
- - func : " install_c_driver "
846
+ - func : " fetch_c_driver_source "
836
847
- func : " compile"
837
848
- func : " clang-tidy"
838
849
839
850
- name : compile_and_test_with_shared_libs
840
851
commands :
841
852
- func : " setup"
842
853
- func : " start_mongod"
843
- - func : " install_c_driver "
854
+ - func : " fetch_c_driver_source "
844
855
- func : " compile"
845
856
vars :
846
857
RUN_DISTCHECK : 1
847
858
- func : " clone_drivers-evergreen-tools"
848
859
- func : " run_kms_servers"
860
+ - func : " install_c_driver"
849
861
- func : " test"
850
862
851
863
- name : compile_and_test_with_shared_libs_extra_alignment
852
864
commands :
853
865
- func : " setup"
854
866
- func : " start_mongod"
855
- - func : " install_c_driver "
867
+ - func : " fetch_c_driver_source "
856
868
vars :
857
869
BSON_EXTRA_ALIGNMENT : 1
858
870
- func : " compile"
859
871
- func : " clone_drivers-evergreen-tools"
860
872
- func : " run_kms_servers"
873
+ - func : " install_c_driver"
861
874
- func : " test"
862
875
863
876
- name : compile_and_test_with_shared_libs_cxx20
864
877
commands :
865
878
- func : " setup"
866
879
- func : " start_mongod"
867
- - func : " install_c_driver "
880
+ - func : " fetch_c_driver_source "
868
881
- func : " compile"
869
882
vars :
870
883
RUN_DISTCHECK : 1
871
884
REQUIRED_CXX_STANDARD : 20
872
885
- func : " clone_drivers-evergreen-tools"
873
886
- func : " run_kms_servers"
887
+ - func : " install_c_driver"
874
888
- func : " test"
875
889
vars :
876
890
REQUIRED_CXX_STANDARD : 20
@@ -880,14 +894,15 @@ tasks:
880
894
commands :
881
895
- func : " setup"
882
896
- func : " start_mongod"
883
- - func : " install_c_driver "
897
+ - func : " fetch_c_driver_source "
884
898
vars :
885
899
BSON_EXTRA_ALIGNMENT : 1
886
900
- func : " compile"
887
901
vars :
888
902
REQUIRED_CXX_STANDARD : 20
889
903
- func : " clone_drivers-evergreen-tools"
890
904
- func : " run_kms_servers"
905
+ - func : " install_c_driver"
891
906
- func : " test"
892
907
vars :
893
908
REQUIRED_CXX_STANDARD : 20
@@ -897,13 +912,13 @@ tasks:
897
912
commands :
898
913
- func : " setup"
899
914
- func : " start_mongod"
900
- - func : " install_c_driver "
915
+ - func : " fetch_c_driver_source "
901
916
- func : " compile"
902
917
903
918
- name : compile_without_tests
904
919
commands :
905
920
- func : " setup"
906
- - func : " install_c_driver "
921
+ - func : " fetch_c_driver_source "
907
922
- func : " compile"
908
923
vars :
909
924
ENABLE_TESTS : OFF
@@ -914,7 +929,7 @@ tasks:
914
929
- func : " start_mongod"
915
930
vars :
916
931
AUTH : auth
917
- - func : " install_c_driver "
932
+ - func : " fetch_c_driver_source "
918
933
- func : " compile"
919
934
- func : " test auth"
920
935
- func : " test atlas connectivity"
@@ -923,13 +938,14 @@ tasks:
923
938
commands :
924
939
- func : " setup"
925
940
- func : " start_mongod"
926
- - func : " install_c_driver "
941
+ - func : " fetch_c_driver_source "
927
942
- func : " compile"
928
943
vars :
929
944
USE_STATIC_LIBS : 1
930
945
RUN_DISTCHECK : 1
931
946
- func : " clone_drivers-evergreen-tools"
932
947
- func : " run_kms_servers"
948
+ - func : " install_c_driver"
933
949
- func : " test"
934
950
vars :
935
951
USE_STATIC_LIBS : 1
@@ -938,19 +954,39 @@ tasks:
938
954
commands :
939
955
- func : " setup"
940
956
- func : " start_mongod"
941
- - func : " install_c_driver "
957
+ - func : " fetch_c_driver_source "
942
958
vars :
943
959
BSON_EXTRA_ALIGNMENT : 1
944
960
- func : " compile"
945
961
vars :
946
962
USE_STATIC_LIBS : 1
947
963
- func : " clone_drivers-evergreen-tools"
948
964
- func : " run_kms_servers"
965
+ - func : " install_c_driver"
949
966
- func : " test"
950
967
vars :
951
968
USE_STATIC_LIBS : 1
952
969
953
970
- name : compile_and_test_with_shared_libs_replica_set
971
+ commands :
972
+ - func : " setup"
973
+ - func : " start_mongod"
974
+ vars :
975
+ TOPOLOGY : " replica_set"
976
+ - func : " fetch_c_driver_source"
977
+ - func : " compile"
978
+ vars :
979
+ RUN_DISTCHECK : 1
980
+ - func : " clone_drivers-evergreen-tools"
981
+ - func : " run_kms_servers"
982
+ - func : " install_c_driver"
983
+ - func : " test"
984
+
985
+ # Auto downloading the C driver in the C++ build does not currently include
986
+ # support for libmongocrypt, therefore it is not configured with
987
+ # -DENABLE_CLIENT_SIDE_ENCRYPTION=ON. For now, CSFLE tests will need to have
988
+ # a manually configured C driver, hence the need to seperate this task.
989
+ - name : compile_and_test_with_shared_libs_replica_set_with_libmongocrypt
954
990
commands :
955
991
- func : " setup"
956
992
- func : " start_mongod"
@@ -967,7 +1003,7 @@ tasks:
967
1003
- name : uninstall_check
968
1004
commands :
969
1005
- func : " setup"
970
- - func : " install_c_driver "
1006
+ - func : " fetch_c_driver_source "
971
1007
- func : " compile"
972
1008
- command : expansions.update
973
1009
params :
@@ -987,7 +1023,7 @@ tasks:
987
1023
- name : uninstall_check_windows
988
1024
commands :
989
1025
- func : " setup"
990
- - func : " install_c_driver "
1026
+ - func : " fetch_c_driver_source "
991
1027
- func : " compile"
992
1028
- command : expansions.update
993
1029
params :
@@ -1023,7 +1059,7 @@ tasks:
1023
1059
export CMAKE="$(find_cmake_latest)"
1024
1060
cd build
1025
1061
$CMAKE ..
1026
- $CMAKE --build . -- -j 8
1062
+ $CMAKE --build . -- -j $(nproc)
1027
1063
./hello_mongocxx
1028
1064
1029
1065
- name : debian-package-build
@@ -1098,7 +1134,7 @@ tasks:
1098
1134
- name : test_mongohouse
1099
1135
commands :
1100
1136
- func : " setup"
1101
- - func : " install_c_driver "
1137
+ - func : " fetch_c_driver_source "
1102
1138
- func : " compile"
1103
1139
- func : " build_mongohouse"
1104
1140
- func : " run_mongohouse"
@@ -1113,7 +1149,7 @@ tasks:
1113
1149
# Authentication with versioned API should already be tested
1114
1150
# in the C driver.
1115
1151
AUTH : noauth
1116
- - func : " install_c_driver "
1152
+ - func : " fetch_c_driver_source "
1117
1153
- func : " compile"
1118
1154
- func : " clone_drivers-evergreen-tools"
1119
1155
- func : " run_kms_servers"
@@ -1128,7 +1164,7 @@ tasks:
1128
1164
vars :
1129
1165
ORCHESTRATION_FILE : versioned-api-testing.json
1130
1166
AUTH : noauth
1131
- - func : " install_c_driver "
1167
+ - func : " fetch_c_driver_source "
1132
1168
- func : " compile"
1133
1169
- func : " clone_drivers-evergreen-tools"
1134
1170
- func : " run_kms_servers"
@@ -1220,7 +1256,7 @@ buildvariants:
1220
1256
matrix_spec : {os: "ubuntu-1804", mongodb_version: "*"}
1221
1257
display_name : " ${os} replica set (MongoDB ${mongodb_version})"
1222
1258
tasks :
1223
- - name : compile_and_test_with_shared_libs_replica_set
1259
+ - name : compile_and_test_with_shared_libs_replica_set_with_libmongocrypt
1224
1260
1225
1261
- matrix_name : " auth"
1226
1262
matrix_spec : {os: "*", mongodb_version: "latest"}
@@ -1265,7 +1301,7 @@ buildvariants:
1265
1301
- name : compile_and_test_with_shared_libs_extra_alignment_cxx20
1266
1302
- name : compile_and_test_with_static_libs
1267
1303
- name : compile_and_test_with_static_libs_extra_alignment
1268
- - name : compile_and_test_with_shared_libs_replica_set
1304
+ - name : compile_and_test_with_shared_libs_replica_set_with_libmongocrypt
1269
1305
- name : build_example_with_add_subdirectory
1270
1306
distros :
1271
1307
- rhel90-large
@@ -1288,7 +1324,7 @@ buildvariants:
1288
1324
- name : compile_and_test_with_shared_libs_extra_alignment_cxx20
1289
1325
- name : compile_and_test_with_static_libs
1290
1326
- name : compile_and_test_with_static_libs_extra_alignment
1291
- - name : compile_and_test_with_shared_libs_replica_set
1327
+ - name : compile_and_test_with_shared_libs_replica_set_with_libmongocrypt
1292
1328
- name : build_example_with_add_subdirectory
1293
1329
distros :
1294
1330
- rhel90-arm64-large
@@ -1310,7 +1346,7 @@ buildvariants:
1310
1346
- name : compile_and_test_with_shared_libs_extra_alignment_cxx20
1311
1347
- name : compile_and_test_with_static_libs
1312
1348
- name : compile_and_test_with_static_libs_extra_alignment
1313
- - name : compile_and_test_with_shared_libs_replica_set
1349
+ - name : compile_and_test_with_shared_libs_replica_set_with_libmongocrypt
1314
1350
- name : build_example_with_add_subdirectory
1315
1351
distros :
1316
1352
- debian11-large
@@ -1354,7 +1390,7 @@ buildvariants:
1354
1390
- name : compile_and_test_with_shared_libs_extra_alignment
1355
1391
- name : compile_and_test_with_static_libs
1356
1392
- name : compile_and_test_with_static_libs_extra_alignment
1357
- - name : compile_and_test_with_shared_libs_replica_set
1393
+ - name : compile_and_test_with_shared_libs_replica_set_with_libmongocrypt
1358
1394
- name : build_example_with_add_subdirectory
1359
1395
distros :
1360
1396
- debian10-large
@@ -1381,6 +1417,18 @@ buildvariants:
1381
1417
- debian10-large
1382
1418
- name : uninstall_check
1383
1419
1420
+ # Add matrix for specification test requirement of mongocryptd:
1421
+ # "Drivers MUST run all tests with mongocryptd on at least one platform for all tested server versions (4.2+)."
1422
+ - matrix_name : " mongocryptd"
1423
+ matrix_spec :
1424
+ os : " ubuntu-1804"
1425
+ mongodb_version : ["4.2", "4.4", "5.0", "latest"]
1426
+ display_name : " ${os} (MongoDB ${mongodb_version}) with mongocryptd"
1427
+ tasks :
1428
+ - name : compile_and_test_with_shared_libs_replica_set_with_libmongocrypt
1429
+ expansions :
1430
+ use_mongocryptd : true
1431
+
1384
1432
- name : ubuntu2004-release-latest
1385
1433
display_name : " Ubuntu 20.04 Release (MongoDB Latest)"
1386
1434
expansions :
@@ -1396,7 +1444,7 @@ buildvariants:
1396
1444
- name : compile_and_test_with_shared_libs_extra_alignment
1397
1445
- name : compile_and_test_with_static_libs
1398
1446
- name : compile_and_test_with_static_libs_extra_alignment
1399
- - name : compile_and_test_with_shared_libs_replica_set
1447
+ - name : compile_and_test_with_shared_libs_replica_set_with_libmongocrypt
1400
1448
- name : build_example_with_add_subdirectory
1401
1449
distros :
1402
1450
- ubuntu2004-large
@@ -1439,7 +1487,7 @@ buildvariants:
1439
1487
- name : compile_and_test_with_shared_libs_extra_alignment
1440
1488
- name : compile_and_test_with_static_libs
1441
1489
- name : compile_and_test_with_static_libs_extra_alignment
1442
- - name : compile_and_test_with_shared_libs_replica_set
1490
+ - name : compile_and_test_with_shared_libs_replica_set_with_libmongocrypt
1443
1491
- name : build_example_with_add_subdirectory
1444
1492
distros :
1445
1493
- ubuntu1804-build
0 commit comments