summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRandolph Tan <randolph@10gen.com>2020-04-01 13:52:04 -0400
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2020-05-28 17:40:41 +0000
commit2571f4b4e933f48b2ed48fa80ace44667043c2b9 (patch)
tree3ece8b6d18d9fc1a420db7a354ef30ad6bb32eb6
parent85f1ed156770a7821d39ff1704327d4b9a7c41ab (diff)
downloadmongo-2571f4b4e933f48b2ed48fa80ace44667043c2b9.tar.gz
SERVER-45554 Add more core/txns sharding passthrough suites
(cherry picked from commit 2cd751b7a81912d0f6bc311423903c17e15eba48)
-rw-r--r--buildscripts/resmokeconfig/suites/causally_consistent_jscore_passthrough.yml2
-rw-r--r--buildscripts/resmokeconfig/suites/causally_consistent_jscore_passthrough_auth.yml2
-rw-r--r--buildscripts/resmokeconfig/suites/logical_session_cache_sharding_100ms_refresh_jscore_passthrough.yml2
-rw-r--r--buildscripts/resmokeconfig/suites/logical_session_cache_sharding_100ms_refresh_jscore_txns_passthrough.yml78
-rw-r--r--buildscripts/resmokeconfig/suites/logical_session_cache_sharding_10sec_refresh_jscore_passthrough.yml2
-rw-r--r--buildscripts/resmokeconfig/suites/logical_session_cache_sharding_1sec_refresh_jscore_passthrough.yml2
-rw-r--r--buildscripts/resmokeconfig/suites/logical_session_cache_sharding_default_refresh_jscore_passthrough.yml2
-rw-r--r--buildscripts/resmokeconfig/suites/sharded_causally_consistent_jscore_passthrough.yml2
-rw-r--r--buildscripts/resmokeconfig/suites/sharded_jscore_op_query_txns.yml67
-rw-r--r--buildscripts/resmokeconfig/suites/sharding_jscore_op_query_passthrough.yml2
-rw-r--r--buildscripts/resmokeconfig/suites/sharding_jscore_passthrough.yml2
-rw-r--r--etc/evergreen.yml20
12 files changed, 174 insertions, 9 deletions
diff --git a/buildscripts/resmokeconfig/suites/causally_consistent_jscore_passthrough.yml b/buildscripts/resmokeconfig/suites/causally_consistent_jscore_passthrough.yml
index 746dc36c311..60175360606 100644
--- a/buildscripts/resmokeconfig/suites/causally_consistent_jscore_passthrough.yml
+++ b/buildscripts/resmokeconfig/suites/causally_consistent_jscore_passthrough.yml
@@ -4,7 +4,7 @@ selector:
roots:
- jstests/core/**/*.js
exclude_files:
- # In MongoDB 4.0, transactions are not supported in sharded clusters.
+ # These tests are run in causally_consistent_jscore_txns_passthrough.yml.
- jstests/core/txns/**/*.js
# Cannot specify afterClusterTime and afterOpTime.
- jstests/core/read_after_optime.js
diff --git a/buildscripts/resmokeconfig/suites/causally_consistent_jscore_passthrough_auth.yml b/buildscripts/resmokeconfig/suites/causally_consistent_jscore_passthrough_auth.yml
index 1728969d16f..282eea6074f 100644
--- a/buildscripts/resmokeconfig/suites/causally_consistent_jscore_passthrough_auth.yml
+++ b/buildscripts/resmokeconfig/suites/causally_consistent_jscore_passthrough_auth.yml
@@ -13,7 +13,7 @@ selector:
roots:
- jstests/core/**/*.js
exclude_files:
- # In MongoDB 4.0, transactions are not supported in sharded clusters.
+ # TODO: SERVER-47185 Consider creating auth version of jscore_txn test suites
- jstests/core/txns/**/*.js
# Skip any tests that run with auth explicitly.
- jstests/core/*[aA]uth*.js
diff --git a/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_100ms_refresh_jscore_passthrough.yml b/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_100ms_refresh_jscore_passthrough.yml
index 451de036802..e70f905f6c2 100644
--- a/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_100ms_refresh_jscore_passthrough.yml
+++ b/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_100ms_refresh_jscore_passthrough.yml
@@ -4,7 +4,7 @@ selector:
roots:
- jstests/core/**/*.js
exclude_files:
- # In MongoDB 4.0, transactions are not supported in sharded clusters.
+ # These tests are run in logical_session_cache_sharding_100ms_refresh_jscore_txns_passthrough.yml.
- jstests/core/txns/**/*.js
# The following tests fail because a certain command or functionality is not supported by
# mongos. This command or functionality is placed in a comment next to the failing test.
diff --git a/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_100ms_refresh_jscore_txns_passthrough.yml b/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_100ms_refresh_jscore_txns_passthrough.yml
new file mode 100644
index 00000000000..7bbc5e7bb28
--- /dev/null
+++ b/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_100ms_refresh_jscore_txns_passthrough.yml
@@ -0,0 +1,78 @@
+test_kind: js_test
+
+selector:
+ roots:
+ - jstests/core/txns/**/*.js
+ exclude_files:
+ # Profile can only be run against the admin database on mongos.
+ - jstests/core/txns/transactions_profiling.js
+ - jstests/core/txns/transactions_profiling_with_drops.js
+
+ # No featureCompatibilityVersion parameter on mongos.
+ - jstests/core/txns/abort_unprepared_transactions_on_FCV_downgrade.js
+ - jstests/core/txns/downgrade_fcv_while_large_partial_txn_in_progress.js
+ - jstests/core/txns/large_transactions_require_fcv42.js
+
+ # Implicitly creates a database through a collection rename, which does not work in a sharded
+ # cluster.
+ - jstests/core/txns/transactions_block_ddl.js
+
+ # transactionLifetimeLimitSeconds parameter is not available in mongos.
+ - jstests/core/txns/abort_expired_transaction.js
+ - jstests/core/txns/abort_transaction_thread_does_not_block_on_locks.js
+ - jstests/core/txns/kill_op_on_txn_expiry.js
+
+ # Uses hangAfterCollectionInserts failpoint not available on mongos.
+ - jstests/core/txns/speculative_snapshot_includes_all_writes.js
+
+ # View tests aren't expected to work when collections are implicitly sharded.
+ - jstests/core/txns/view_reads_in_transaction.js
+
+ # TODO SERVER-46187: maxTimeMS doesn't work correctly for insert on mongos.
+ - jstests/core/txns/write_conflicts_with_non_txns.js
+
+ # Writes to the local database are not allowed through mongos.
+ # TODO SERVER-28756: Mongos CSRS write retry logic drops txnNumbers.
+ - jstests/core/txns/banned_txn_dbs.js
+
+ exclude_with_any_tags:
+ - assumes_against_mongod_not_mongos
+ # Tests tagged with the following will fail because they assume collections are not sharded.
+ - assumes_no_implicit_collection_creation_after_drop
+ - assumes_no_implicit_index_creation
+ - assumes_unsharded_collection
+ - cannot_create_unique_index_when_using_hashed_shard_key
+ # Transactions are not allowed to operate on capped collections.
+ - requires_capped
+ # Prepare is not a command on mongos.
+ - uses_prepare_transaction
+
+executor:
+ archive:
+ hooks:
+ - CheckReplDBHash
+ - ValidateCollections
+ config:
+ shell_options:
+ readMode: commands
+ eval: load("jstests/libs/override_methods/implicitly_shard_accessed_collections.js")
+ hooks:
+ - class: CheckReplDBHash
+ - class: ValidateCollections
+ - class: CleanEveryN
+ n: 20
+ fixture:
+ class: ShardedClusterFixture
+ num_shards: 2
+ enable_balancer: false
+ mongos_options:
+ set_parameters:
+ enableTestCommands: 1
+ disableLogicalSessionCacheRefresh: false
+ logicalSessionRefreshMillis: 100
+ mongod_options:
+ set_parameters:
+ enableTestCommands: 1
+ disableLogicalSessionCacheRefresh: false
+ logicalSessionRefreshMillis: 100
+ num_rs_nodes_per_shard: 2
diff --git a/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_10sec_refresh_jscore_passthrough.yml b/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_10sec_refresh_jscore_passthrough.yml
index 4f86e857d2b..a7f47da28ac 100644
--- a/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_10sec_refresh_jscore_passthrough.yml
+++ b/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_10sec_refresh_jscore_passthrough.yml
@@ -4,7 +4,7 @@ selector:
roots:
- jstests/core/**/*.js
exclude_files:
- # In MongoDB 4.0, transactions are not supported in sharded clusters.
+ # These tests are run in logical_session_cache_sharding_100ms_refresh_jscore_txns_passthrough.yml.
- jstests/core/txns/**/*.js
# The following tests fail because a certain command or functionality is not supported by
# mongos. This command or functionality is placed in a comment next to the failing test.
diff --git a/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_1sec_refresh_jscore_passthrough.yml b/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_1sec_refresh_jscore_passthrough.yml
index a75746c8596..2e2395a3ffb 100644
--- a/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_1sec_refresh_jscore_passthrough.yml
+++ b/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_1sec_refresh_jscore_passthrough.yml
@@ -4,7 +4,7 @@ selector:
roots:
- jstests/core/**/*.js
exclude_files:
- # In MongoDB 4.0, transactions are not supported in sharded clusters.
+ # These tests are run in logical_session_cache_sharding_100ms_refresh_jscore_txns_passthrough.yml.
- jstests/core/txns/**/*.js
# The following tests fail because a certain command or functionality is not supported by
# mongos. This command or functionality is placed in a comment next to the failing test.
diff --git a/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_default_refresh_jscore_passthrough.yml b/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_default_refresh_jscore_passthrough.yml
index 2abb080d45b..2a601f4d426 100644
--- a/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_default_refresh_jscore_passthrough.yml
+++ b/buildscripts/resmokeconfig/suites/logical_session_cache_sharding_default_refresh_jscore_passthrough.yml
@@ -4,7 +4,7 @@ selector:
roots:
- jstests/core/**/*.js
exclude_files:
- # In MongoDB 4.0, transactions are not supported in sharded clusters.
+ # These tests are run in logical_session_cache_sharding_100ms_refresh_jscore_txns_passthrough.yml.
- jstests/core/txns/**/*.js
# The following tests fail because a certain command or functionality is not supported by
# mongos. This command or functionality is placed in a comment next to the failing test.
diff --git a/buildscripts/resmokeconfig/suites/sharded_causally_consistent_jscore_passthrough.yml b/buildscripts/resmokeconfig/suites/sharded_causally_consistent_jscore_passthrough.yml
index 90e4afdeb53..0bc6587ac8c 100644
--- a/buildscripts/resmokeconfig/suites/sharded_causally_consistent_jscore_passthrough.yml
+++ b/buildscripts/resmokeconfig/suites/sharded_causally_consistent_jscore_passthrough.yml
@@ -6,7 +6,7 @@ selector:
roots:
- jstests/core/**/*.js
exclude_files:
- # In MongoDB 4.0, transactions are not supported in sharded clusters.
+ # These tests are run in sharded_causally_consistent_jscore_txns_passthrough.
- jstests/core/txns/**/*.js
# Not expected to pass with replica-sets.
- jstests/core/opcounters_write_cmd.js
diff --git a/buildscripts/resmokeconfig/suites/sharded_jscore_op_query_txns.yml b/buildscripts/resmokeconfig/suites/sharded_jscore_op_query_txns.yml
new file mode 100644
index 00000000000..f5273a084fc
--- /dev/null
+++ b/buildscripts/resmokeconfig/suites/sharded_jscore_op_query_txns.yml
@@ -0,0 +1,67 @@
+# This test suite exercises core, generic transactions behavior. The tests in this suite, pulled
+# from 'jstests/core/txns', should be "topology agnostic". They ideally generalize to single replica
+# sets and sharded clusters.
+
+test_kind: js_test
+selector:
+ roots:
+ - jstests/core/txns/**/*.js
+ exclude_files:
+ # Profile can only be run against the admin database on mongos.
+ - jstests/core/txns/transactions_profiling.js
+ - jstests/core/txns/transactions_profiling_with_drops.js
+
+ # No featureCompatibilityVersion parameter on mongos.
+ - jstests/core/txns/abort_unprepared_transactions_on_FCV_downgrade.js
+ - jstests/core/txns/downgrade_fcv_while_large_partial_txn_in_progress.js
+ - jstests/core/txns/large_transactions_require_fcv42.js
+
+ # Implicitly creates a database through a collection rename, which does not work in a sharded
+ # cluster.
+ - jstests/core/txns/transactions_block_ddl.js
+
+ # transactionLifetimeLimitSeconds parameter is not available in mongos.
+ - jstests/core/txns/abort_expired_transaction.js
+ - jstests/core/txns/abort_transaction_thread_does_not_block_on_locks.js
+ - jstests/core/txns/kill_op_on_txn_expiry.js
+
+ # Uses hangAfterCollectionInserts failpoint not available on mongos.
+ - jstests/core/txns/speculative_snapshot_includes_all_writes.js
+
+ # TODO SERVER-46187: maxTimeMS doesn't work correctly for insert on mongos.
+ - jstests/core/txns/write_conflicts_with_non_txns.js
+
+ # Writes to the local database are not allowed through mongos.
+ # TODO SERVER-28756: Mongos CSRS write retry logic drops txnNumbers.
+ - jstests/core/txns/banned_txn_dbs.js
+
+ exclude_with_any_tags:
+ - assumes_against_mongod_not_mongos
+ # Transactions are not allowed to operate on capped collections.
+ - requires_capped
+ # Prepare is not a command on mongos.
+ - uses_prepare_transaction
+executor:
+ archive:
+ hooks:
+ - ValidateCollections
+ config:
+ shell_options:
+ rpcProtocols: opQueryOnly
+ readMode: commands
+ hooks:
+ - class: CheckReplDBHash
+ - class: ValidateCollections
+ - class: CleanEveryN
+ n: 20
+ fixture:
+ class: ShardedClusterFixture
+ mongos_options:
+ set_parameters:
+ enableTestCommands: 1
+ mongod_options:
+ set_parameters:
+ enableTestCommands: 1
+ enable_sharding:
+ - test
+ num_rs_nodes_per_shard: 2
diff --git a/buildscripts/resmokeconfig/suites/sharding_jscore_op_query_passthrough.yml b/buildscripts/resmokeconfig/suites/sharding_jscore_op_query_passthrough.yml
index b117bf1640f..e501d56f972 100644
--- a/buildscripts/resmokeconfig/suites/sharding_jscore_op_query_passthrough.yml
+++ b/buildscripts/resmokeconfig/suites/sharding_jscore_op_query_passthrough.yml
@@ -4,7 +4,7 @@ selector:
roots:
- jstests/core/**/*.js
exclude_files:
- # In MongoDB 4.0, transactions are not supported in sharded clusters.
+ # These tests are run in sharded_jscore_op_query_txns.
- jstests/core/txns/**/*.js
# The following tests fail because a certain command or functionality is not supported on
# mongos. This command or functionality is placed in a comment next to the failing test.
diff --git a/buildscripts/resmokeconfig/suites/sharding_jscore_passthrough.yml b/buildscripts/resmokeconfig/suites/sharding_jscore_passthrough.yml
index 7a10e7b5d49..e24d4f83a69 100644
--- a/buildscripts/resmokeconfig/suites/sharding_jscore_passthrough.yml
+++ b/buildscripts/resmokeconfig/suites/sharding_jscore_passthrough.yml
@@ -4,7 +4,7 @@ selector:
roots:
- jstests/core/**/*.js
exclude_files:
- # In MongoDB 4.0, transactions are not supported in sharded clusters.
+ # These tests are run in sharded_jscore_txns.
- jstests/core/txns/**/*.js
# The following tests fail because a certain command or functionality is not supported on
# mongos. This command or functionality is placed in a comment next to the failing test.
diff --git a/etc/evergreen.yml b/etc/evergreen.yml
index 85bd8e9ecbc..61fa8569b54 100644
--- a/etc/evergreen.yml
+++ b/etc/evergreen.yml
@@ -5189,6 +5189,15 @@ tasks:
resmoke_args: --suites=sharded_jscore_txns --storageEngine=wiredTiger
- <<: *task_template
+ name: sharded_jscore_op_query_txns
+ tags: ["sharding", "jscore", "txns"]
+ commands:
+ - func: "do setup"
+ - func: "run tests"
+ vars:
+ resmoke_args: --suites=sharded_jscore_op_query_txns --storageEngine=wiredTiger
+
+- <<: *task_template
name: sharded_jscore_txns_without_snapshot
tags: ["sharding", "wo_snapshot", "jscore"]
commands:
@@ -6258,6 +6267,17 @@ tasks:
resmoke_args: --storageEngine=wiredTiger
fallback_num_sub_suites: 48
+- name: logical_session_cache_sharding_100ms_refresh_jscore_txns_passthrough_gen
+ tags: ["logical_session_cache"]
+ depends_on:
+ - name: jsCore
+ commands:
+ - func: "generate resmoke tasks"
+ vars:
+ depends_on: jsCore
+ resmoke_args: --storageEngine=wiredTiger
+ fallback_num_sub_suites: 10
+
- name: logical_session_cache_sharding_1sec_refresh_jscore_passthrough_gen
tags: ["logical_session_cache", "one_sec"]
depends_on: