diff options
author | Rishab Joshi <rishab.joshi@mongodb.com> | 2022-06-30 14:44:28 +0000 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2022-06-30 15:15:03 +0000 |
commit | e68b01fd6ba6fb4109005b86c417823c067b0cc9 (patch) | |
tree | bca9faa313e050ff5629d3c70ef5b23353334085 /buildscripts | |
parent | c3018cbbe041f0398cba15b94f8b10ec5b98db57 (diff) | |
download | mongo-e68b01fd6ba6fb4109005b86c417823c067b0cc9.tar.gz |
SERVER-66892 Introduce change collection passthrough suite.
Diffstat (limited to 'buildscripts')
4 files changed, 125 insertions, 0 deletions
diff --git a/buildscripts/resmokeconfig/fully_disabled_feature_flags.yml b/buildscripts/resmokeconfig/fully_disabled_feature_flags.yml index 1188d8163cc..a9ddf90bd65 100644 --- a/buildscripts/resmokeconfig/fully_disabled_feature_flags.yml +++ b/buildscripts/resmokeconfig/fully_disabled_feature_flags.yml @@ -12,3 +12,6 @@ # released create the transactions collection index and is only meant to be enabled adhoc, so only # its targeted tests should enable it. - featureFlagAlwaysCreateConfigTransactionsPartialIndexOnStepUp +# Disable 'featureFlagServerlessChangeStreams' until the change collection becomes stable. +# TODO SERVER-67267 remove the flag. +- featureFlagServerlessChangeStreams diff --git a/buildscripts/resmokeconfig/suites/change_streams_multitenant_passthrough.yml b/buildscripts/resmokeconfig/suites/change_streams_multitenant_passthrough.yml new file mode 100644 index 00000000000..90f9a7143a0 --- /dev/null +++ b/buildscripts/resmokeconfig/suites/change_streams_multitenant_passthrough.yml @@ -0,0 +1,56 @@ +test_kind: js_test + +selector: + roots: + - jstests/change_streams/**/*.js + exclude_files: + # TODO SERVER-66840 investigate the failing test case. + - jstests/change_streams/projection_fakes_internal_event.js + - jstests/change_streams/only_wake_getmore_for_relevant_changes.js + exclude_with_any_tags: + ## + # The next tags correspond to the special errors thrown by the + # set_read_and_write_concerns.js override when it refuses to replace the readConcern or + # writeConcern of a particular command. Above each tag are the message(s) that cause the tag to be + # warranted. + ## + # "Cowardly refusing to override write concern of command: ..." + - assumes_write_concern_unchanged + +executor: + archive: + hooks: + - CheckReplDBHash + - ValidateCollections + config: + shell_options: + global_vars: + TestData: + defaultReadConcernLevel: null + enableMajorityReadConcern: '' + # Enable causal consistency for change streams suites using 1 node replica sets. See + # change_streams.yml for detailed explanation. + #TODO SERVER-67267 load 'inject_tenant_prefix.js'. + eval: >- + var testingReplication = true; + load('jstests/libs/override_methods/set_read_and_write_concerns.js'); + load('jstests/libs/override_methods/enable_causal_consistency_without_read_pref.js'); + load('jstests/libs/override_methods/override_fixtures_changestream_multitenancy.js'); + hooks: + # The CheckReplDBHash hook waits until all operations have replicated to and have been applied + # on the secondaries, so we run the ValidateCollections hook after it to ensure we're + # validating the entire contents of the collection. + - class: CheckReplDBHash + - class: ValidateCollections + - class: CleanEveryN + n: 20 + fixture: + class: ReplicaSetFixture + mongod_options: + bind_ip_all: '' + set_parameters: + enableTestCommands: 1 + featureFlagServerlessChangeStreams: true + failpoint.assertChangeStreamNssCollection: + "{'mode': 'alwaysOn', 'data': {'collectionName': 'system.change_collection'}}" + num_nodes: 2 diff --git a/buildscripts/resmokeconfig/suites/change_streams_multitenant_sharded_collections_passthrough.yml b/buildscripts/resmokeconfig/suites/change_streams_multitenant_sharded_collections_passthrough.yml new file mode 100644 index 00000000000..7322196331b --- /dev/null +++ b/buildscripts/resmokeconfig/suites/change_streams_multitenant_sharded_collections_passthrough.yml @@ -0,0 +1,65 @@ +test_kind: js_test + +selector: + roots: + - jstests/change_streams/**/*.js + exclude_files: + # TODO SERVER-66840 investigate the failing test case. + - jstests/change_streams/only_wake_getmore_for_relevant_changes.js + - jstests/change_streams/projection_fakes_internal_event.js + exclude_with_any_tags: + ## + # The next tags correspond to the special errors thrown by the + # set_read_and_write_concerns.js override when it refuses to replace the readConcern or + # writeConcern of a particular command. Above each tag are the message(s) that cause the tag to be + # warranted. + ## + # "Cowardly refusing to override write concern of command: ..." + - assumes_write_concern_unchanged + # Exclude any that assume sharding is disabled. + - assumes_against_mongod_not_mongos + # This passthrough implicitly shards the accessed collections. Do not run tests that assume + # unsharded collections. + - assumes_unsharded_collection + +executor: + archive: + hooks: + - CheckReplDBHash + - ValidateCollections + config: + shell_options: + global_vars: + TestData: + defaultReadConcernLevel: null + enableMajorityReadConcern: '' + # Enable causal consistency for change streams suites using 1 node replica sets. See + # change_streams.yml for detailed explanation. + eval: >- + var testingReplication = true; + load('jstests/libs/override_methods/set_read_and_write_concerns.js'); + load('jstests/libs/override_methods/enable_causal_consistency_without_read_pref.js'); + load('jstests/libs/override_methods/implicitly_shard_accessed_collections.js'); + load('jstests/libs/override_methods/override_fixtures_changestream_multitenancy.js'); + hooks: + - class: CheckReplDBHash + - class: ValidateCollections + - class: CleanEveryN + n: 20 + fixture: + class: ShardedClusterFixture + num_shards: 2 + mongos_options: + bind_ip_all: '' + set_parameters: + enableTestCommands: 1 + mongod_options: + bind_ip_all: '' + set_parameters: + enableTestCommands: 1 + periodicNoopIntervalSecs: 1 + writePeriodicNoops: true + # TODO SERVER-67267 check if the feature flag can be removed. + failpoint.forceEnableChangeCollectionsMode: "{mode: 'alwaysOn'}" + failpoint.assertChangeStreamNssCollection: + "{'mode': 'alwaysOn', 'data': {'collectionName': 'system.change_collection'}}" diff --git a/buildscripts/resmokeconfig/suites/serverless.yml b/buildscripts/resmokeconfig/suites/serverless.yml index 9c2066ddf3e..eeef77194a2 100644 --- a/buildscripts/resmokeconfig/suites/serverless.yml +++ b/buildscripts/resmokeconfig/suites/serverless.yml @@ -3,6 +3,7 @@ test_kind: js_test selector: roots: - jstests/serverless/*.js + - jstests/serverless/change_streams/**/*.js executor: config: |