From 1a67d4a06dee8950993855944566ba6996d96b21 Mon Sep 17 00:00:00 2001 From: Shane Harvey Date: Mon, 22 Nov 2021 13:56:40 -0800 Subject: [PATCH 1/4] PYTHON-3024 Update estimatedDocumentCount test for Atlas Data Lake --- test/data_lake/estimatedDocumentCount.json | 21 +++++++++++++++++++-- test/data_lake/getMore.json | 2 +- test/data_lake/listCollections.json | 2 +- test/data_lake/listDatabases.json | 2 +- test/data_lake/runCommand.json | 2 +- 5 files changed, 23 insertions(+), 6 deletions(-) diff --git a/test/data_lake/estimatedDocumentCount.json b/test/data_lake/estimatedDocumentCount.json index d039a51f06..1a00602890 100644 --- a/test/data_lake/estimatedDocumentCount.json +++ b/test/data_lake/estimatedDocumentCount.json @@ -15,8 +15,25 @@ { "command_started_event": { "command": { - "count": "driverdata" - } + "aggregate": "driverdata", + "pipeline": [ + { + "$collStats": { + "count": {} + } + }, + { + "$group": { + "_id": 1, + "n": { + "$sum": "$count" + } + } + } + ] + }, + "commandName": "aggregate", + "databaseName": "test" } } ] diff --git a/test/data_lake/getMore.json b/test/data_lake/getMore.json index fa1deab4f3..e2e1d4788a 100644 --- a/test/data_lake/getMore.json +++ b/test/data_lake/getMore.json @@ -54,4 +54,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/test/data_lake/listCollections.json b/test/data_lake/listCollections.json index 8d8a8f6c1b..e419f7b3e9 100644 --- a/test/data_lake/listCollections.json +++ b/test/data_lake/listCollections.json @@ -22,4 +22,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/test/data_lake/listDatabases.json b/test/data_lake/listDatabases.json index f8ec9a0bf4..6458148e49 100644 --- a/test/data_lake/listDatabases.json +++ b/test/data_lake/listDatabases.json @@ -21,4 +21,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/test/data_lake/runCommand.json b/test/data_lake/runCommand.json index f72e863ba5..d81ff1a64b 100644 --- a/test/data_lake/runCommand.json +++ b/test/data_lake/runCommand.json @@ -28,4 +28,4 @@ ] } ] -} \ No newline at end of file +} From 8d351fee0af8b603ef3fa5df43864cca5cbb9fec Mon Sep 17 00:00:00 2001 From: Shane Harvey Date: Mon, 22 Nov 2021 17:25:18 -0800 Subject: [PATCH 2/4] PYTHON-3024 Migrate data lake testing to ubuntu 18 --- .evergreen/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.evergreen/config.yml b/.evergreen/config.yml index d4c95105bf..5a7fb7d659 100644 --- a/.evergreen/config.yml +++ b/.evergreen/config.yml @@ -2439,7 +2439,7 @@ buildvariants: - matrix_name: "data-lake-spec-tests" matrix_spec: - platform: ubuntu-16.04 + platform: ubuntu-18.04 python-version: ["3.6", "3.9"] auth: "auth" c-extensions: "*" From 2a807445991e192fa37617a90f90a504cf5c4ab6 Mon Sep 17 00:00:00 2001 From: Shane Harvey Date: Tue, 23 Nov 2021 11:31:32 -0800 Subject: [PATCH 3/4] PYTHON-3024 Fix data lake test commandName -> command_name --- test/data_lake/estimatedDocumentCount.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/data_lake/estimatedDocumentCount.json b/test/data_lake/estimatedDocumentCount.json index 1a00602890..87b385208d 100644 --- a/test/data_lake/estimatedDocumentCount.json +++ b/test/data_lake/estimatedDocumentCount.json @@ -32,8 +32,8 @@ } ] }, - "commandName": "aggregate", - "databaseName": "test" + "command_name": "aggregate", + "database_name": "test" } } ] From fb2aad05afd77a6bc26a077cdbcded8ce43f89ab Mon Sep 17 00:00:00 2001 From: Shane Harvey Date: Tue, 23 Nov 2021 12:24:01 -0800 Subject: [PATCH 4/4] PYTHON-3024 Ensure mongohouse downloads the right build via VARIANT --- .evergreen/config.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.evergreen/config.yml b/.evergreen/config.yml index 5a7fb7d659..c785d8f14b 100644 --- a/.evergreen/config.yml +++ b/.evergreen/config.yml @@ -310,7 +310,9 @@ functions: script: | set -o xtrace ${PREPARE_SHELL} - bash ${DRIVERS_TOOLS}/.evergreen/atlas_data_lake/build-mongohouse-local.sh + # The mongohouse build script needs to be passed the VARIANT variable, see + # https://github.com/10gen/mongohouse/blob/973cc11/evergreen.yaml#L65 + VARIANT=ubuntu1804 bash ${DRIVERS_TOOLS}/.evergreen/atlas_data_lake/build-mongohouse-local.sh - command: shell.exec type: setup params: