Skip to content

Commit

Permalink
RUST-1654 Enable QEv2 tests on serverless (#974)
Browse files Browse the repository at this point in the history
  • Loading branch information
abr-egn authored Oct 12, 2023
1 parent ef3f49a commit cb57ada
Show file tree
Hide file tree
Showing 127 changed files with 374 additions and 340 deletions.
26 changes: 10 additions & 16 deletions .evergreen/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ post:
- func: "upload-mo-artifacts"
- func: "cleanup"

# Cause a timeout if a task does not complete within 90 minutes. TODO RUST-1721: reduce this.
exec_timeout_secs: 5400
# Cause a timeout if a task does not complete within 150 minutes. TODO RUST-1721: reduce this.
exec_timeout_secs: 9000
# What to do if the timeout is hit. Post-task functions will still run.
timeout:
- command: shell.exec
Expand Down Expand Up @@ -324,12 +324,14 @@ buildvariants:
- test-plain-auth

- name: serverless
# TODO RUST-1745: Enable this build variant when the serverless issues are fixed.
disable: true
patchable: false
display_name: "Serverless"
run_on:
- rhel87-small
- rhel80-small
expansions:
LIBMONGOCRYPT_OS: rhel-80-64-bit
AUTH: auth
SSL: ssl
tasks:
- serverless-task-group

Expand Down Expand Up @@ -381,16 +383,6 @@ buildvariants:
tasks:
- test-in-use-encryption-openssl

- name: in-use-encryption-serverless
# TODO RUST-1745: Enable this build variant when the serverless issues are fixed.
disable: true
patchable: false
display_name: In-Use Encryption (Serverless)
run_on:
- rhel87-small
tasks:
- test-in-use-encryption-serverless

- name: load-balancer
display_name: "Load Balancer"
run_on:
Expand All @@ -414,6 +406,7 @@ task_groups:
- func: "init test-results"
- func: "make files executable"
- func: "install rust"
- func: "install junit dependencies"
- command: shell.exec
params:
shell: "bash"
Expand Down Expand Up @@ -445,6 +438,7 @@ task_groups:

tasks:
- "test-serverless"
- "test-in-use-encryption-serverless"

- name: azure-kms-task-group
setup_group_can_fail_task: true
Expand Down Expand Up @@ -1652,9 +1646,9 @@ functions:
params:
working_dir: src
shell: bash
add_expansions_to_env: true
script: |
${PREPARE_SHELL}
${PREPARE_CSFLE}
# Exported without xtrace to avoid leaking credentials
set +o xtrace
Expand Down
1 change: 1 addition & 0 deletions src/db.rs
Original file line number Diff line number Diff line change
Expand Up @@ -394,6 +394,7 @@ impl Database {
};
const SERVER_7_0_0_WIRE_VERSION: i32 = 21;
match max_wire {
None => (),
Some(v) if v >= SERVER_7_0_0_WIRE_VERSION => (),
_ => {
return Err(ErrorKind::IncompatibleServer {
Expand Down
9 changes: 0 additions & 9 deletions src/test/csfle.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ use super::{
FailPointMode,
TestClient,
CLIENT_OPTIONS,
SERVERLESS,
};

type Result<T> = anyhow::Result<T>;
Expand Down Expand Up @@ -2039,10 +2038,6 @@ async fn kms_tls_options() -> Result<()> {
}

async fn fle2v2_ok(name: &str) -> bool {
if *SERVERLESS {
log_uncaptured(format!("Skipping {}: not supported on serverless", name));
return false;
}
let setup_client = Client::test_builder().build().await;
if setup_client.server_version_lt(7, 0) {
log_uncaptured(format!("Skipping {}: not supported on server < 7.0", name));
Expand Down Expand Up @@ -3548,10 +3543,6 @@ async fn fle2_example() -> Result<()> {
log_uncaptured("skipping fle2 example: cannot run on standalone");
return Ok(());
}
if *SERVERLESS {
log_uncaptured("skipping fle2 example: cannot run on serverless");
return Ok(());
}

// Drop data from prior test runs.
test_client
Expand Down
Loading

0 comments on commit cb57ada

Please sign in to comment.