summaryrefslogtreecommitdiff
path: root/jstests
diff options
context:
space:
mode:
authorRandolph Tan <randolph@10gen.com>2017-03-23 13:56:21 -0400
committerRandolph Tan <randolph@10gen.com>2017-03-23 13:56:21 -0400
commitfb956b3b0a48c9b8376575c6adb971a4e0593292 (patch)
treeb4cbaad47c1bf1630baa6005e655947e9ec7835f /jstests
parentd65a41a35dd9caaae77ae2808d7954c757d035ad (diff)
downloadmongo-fb956b3b0a48c9b8376575c6adb971a4e0593292.tar.gz
Revert "SERVER-26315 Override DBCollection.prototype.drop to re-shard collections that are dropped"
This reverts commit 56e66454d14e16689331672734ecde7644a41c78. Conflicts: buildscripts/resmokeconfig/suites/sharded_collections_jscore_passthrough.yml
Diffstat (limited to 'jstests')
-rw-r--r--jstests/aggregation/bugs/ifnull.js5
-rw-r--r--jstests/aggregation/bugs/server21632.js5
-rw-r--r--jstests/aggregation/bugs/server22093.js5
-rw-r--r--jstests/aggregation/bugs/server3253.js4
-rw-r--r--jstests/aggregation/bugs/server6192_server6193.js5
-rw-r--r--jstests/aggregation/expressions/collation_expressions.js3
-rw-r--r--jstests/aggregation/sources/bucket/collation_bucket.js3
-rw-r--r--jstests/aggregation/sources/bucketauto/collation_bucketauto.js3
-rw-r--r--jstests/aggregation/sources/facet/inner_graphlookup.js4
-rw-r--r--jstests/aggregation/sources/facet/inner_lookup.js4
-rw-r--r--jstests/aggregation/sources/geonear/collation_geonear.js3
-rw-r--r--jstests/aggregation/sources/graphLookup/airports.js4
-rw-r--r--jstests/aggregation/sources/graphLookup/basic.js4
-rw-r--r--jstests/aggregation/sources/graphLookup/collation_graphlookup.js4
-rw-r--r--jstests/aggregation/sources/graphLookup/error.js4
-rw-r--r--jstests/aggregation/sources/graphLookup/filter.js4
-rw-r--r--jstests/aggregation/sources/graphLookup/nested_objects.js4
-rw-r--r--jstests/aggregation/sources/graphLookup/socialite.js4
-rw-r--r--jstests/aggregation/sources/group/collation_group.js3
-rw-r--r--jstests/aggregation/sources/lookup/collation_lookup.js3
-rw-r--r--jstests/aggregation/sources/match/collation_match.js3
-rw-r--r--jstests/aggregation/sources/redact/collation_redact.js3
-rw-r--r--jstests/core/agg_hint.js4
-rw-r--r--jstests/core/and2.js5
-rw-r--r--jstests/core/autoid.js5
-rw-r--r--jstests/core/batch_write_collation_estsize.js5
-rw-r--r--jstests/core/batch_write_command_delete.js5
-rw-r--r--jstests/core/batch_write_command_insert.js4
-rw-r--r--jstests/core/batch_write_command_update.js5
-rw-r--r--jstests/core/bench_test1.js3
-rw-r--r--jstests/core/bulk_api_ordered.js4
-rw-r--r--jstests/core/bulk_api_unordered.js5
-rw-r--r--jstests/core/bulk_insert_capped.js4
-rw-r--r--jstests/core/collation.js4
-rw-r--r--jstests/core/collation_update.js4
-rw-r--r--jstests/core/collmod.js4
-rw-r--r--jstests/core/collmod_bad_spec.js4
-rw-r--r--jstests/core/commands_namespace_parsing.js5
-rw-r--r--jstests/core/count11.js4
-rw-r--r--jstests/core/coveredIndex1.js4
-rw-r--r--jstests/core/coveredIndex2.js5
-rw-r--r--jstests/core/covered_index_compound_1.js5
-rw-r--r--jstests/core/covered_index_simple_1.js5
-rw-r--r--jstests/core/covered_index_simple_2.js5
-rw-r--r--jstests/core/covered_index_simple_3.js5
-rw-r--r--jstests/core/covered_index_sort_1.js5
-rw-r--r--jstests/core/covered_index_sort_3.js5
-rw-r--r--jstests/core/covered_multikey.js5
-rw-r--r--jstests/core/create_collection.js4
-rw-r--r--jstests/core/crud_api.js5
-rw-r--r--jstests/core/datasize2.js4
-rw-r--r--jstests/core/doc_validation.js4
-rw-r--r--jstests/core/doc_validation_invalid_validators.js4
-rw-r--r--jstests/core/doc_validation_options.js4
-rw-r--r--jstests/core/drop.js4
-rw-r--r--jstests/core/drop_index.js3
-rw-r--r--jstests/core/ensure_sorted.js5
-rw-r--r--jstests/core/eval2.js3
-rw-r--r--jstests/core/eval3.js3
-rw-r--r--jstests/core/eval4.js3
-rw-r--r--jstests/core/eval_mr.js4
-rw-r--r--jstests/core/evald.js4
-rw-r--r--jstests/core/explain_agg_write_concern.js4
-rw-r--r--jstests/core/explain_distinct.js4
-rw-r--r--jstests/core/explain_find_and_modify.js4
-rw-r--r--jstests/core/explain_missing_collection.js4
-rw-r--r--jstests/core/explain_multi_plan.js5
-rw-r--r--jstests/core/explain_shell_helpers.js4
-rw-r--r--jstests/core/explain_upsert.js5
-rw-r--r--jstests/core/filemd5.js23
-rw-r--r--jstests/core/find_and_modify.js5
-rw-r--r--jstests/core/find_and_modify2.js5
-rw-r--r--jstests/core/find_and_modify3.js5
-rw-r--r--jstests/core/find_and_modify4.js5
-rw-r--r--jstests/core/find_and_modify_concurrent_update.js5
-rw-r--r--jstests/core/find_and_modify_empty_coll.js5
-rw-r--r--jstests/core/find_and_modify_empty_update.js5
-rw-r--r--jstests/core/find_and_modify_server6254.js4
-rw-r--r--jstests/core/find_and_modify_server6582.js4
-rw-r--r--jstests/core/find_and_modify_server6588.js4
-rw-r--r--jstests/core/find_and_modify_server6659.js4
-rw-r--r--jstests/core/find_and_modify_server6865.js5
-rw-r--r--jstests/core/find_and_modify_server6909.js5
-rw-r--r--jstests/core/find_and_modify_server6993.js4
-rw-r--r--jstests/core/find_and_modify_server7660.js4
-rw-r--r--jstests/core/find_and_modify_where.js4
-rw-r--r--jstests/core/fts1.js4
-rw-r--r--jstests/core/fts_blogwild.js4
-rw-r--r--jstests/core/fts_explain.js4
-rw-r--r--jstests/core/fts_index.js4
-rw-r--r--jstests/core/fts_index2.js4
-rw-r--r--jstests/core/fts_index3.js5
-rw-r--r--jstests/core/geo1.js3
-rw-r--r--jstests/core/geo10.js4
-rw-r--r--jstests/core/geo2.js3
-rw-r--r--jstests/core/geo3.js3
-rw-r--r--jstests/core/geo6.js3
-rw-r--r--jstests/core/geo9.js3
-rw-r--r--jstests/core/geo_array0.js4
-rw-r--r--jstests/core/geo_array2.js4
-rw-r--r--jstests/core/geo_borders.js4
-rw-r--r--jstests/core/geo_center_sphere2.js4
-rw-r--r--jstests/core/geo_distinct.js4
-rw-r--r--jstests/core/geo_exactfetch.js4
-rw-r--r--jstests/core/geo_group.js4
-rw-r--r--jstests/core/geo_max.js4
-rw-r--r--jstests/core/geo_mindistance.js4
-rw-r--r--jstests/core/geo_mindistance_boundaries.js4
-rw-r--r--jstests/core/geo_multinest0.js4
-rw-r--r--jstests/core/geo_multinest1.js4
-rw-r--r--jstests/core/geo_near_random1.js4
-rw-r--r--jstests/core/geo_near_random2.js4
-rw-r--r--jstests/core/geo_or.js4
-rw-r--r--jstests/core/geo_queryoptimizer.js3
-rw-r--r--jstests/core/geo_regex0.js4
-rw-r--r--jstests/core/geo_s2dedupnear.js4
-rw-r--r--jstests/core/geo_s2disjoint_holes.js4
-rw-r--r--jstests/core/geo_s2index.js4
-rw-r--r--jstests/core/geo_s2indexversion1.js4
-rw-r--r--jstests/core/geo_s2meridian.js4
-rw-r--r--jstests/core/geo_s2near.js4
-rw-r--r--jstests/core/geo_s2nearComplex.js4
-rw-r--r--jstests/core/geo_s2near_equator_opposite.js4
-rw-r--r--jstests/core/geo_s2nearcorrect.js4
-rw-r--r--jstests/core/geo_s2nongeoarray.js4
-rw-r--r--jstests/core/geo_s2nonstring.js4
-rw-r--r--jstests/core/geo_s2nopoints.js4
-rw-r--r--jstests/core/geo_small_large.js4
-rw-r--r--jstests/core/geo_sort1.js3
-rw-r--r--jstests/core/geo_uniqueDocs2.js4
-rw-r--r--jstests/core/geo_update.js5
-rw-r--r--jstests/core/geo_update_dedup.js4
-rw-r--r--jstests/core/geoa.js3
-rw-r--r--jstests/core/geoc.js3
-rw-r--r--jstests/core/geof.js4
-rw-r--r--jstests/core/getmore_cmd_maxtimems.js4
-rw-r--r--jstests/core/getmore_invalidation.js5
-rw-r--r--jstests/core/group1.js4
-rw-r--r--jstests/core/group2.js4
-rw-r--r--jstests/core/group3.js4
-rw-r--r--jstests/core/group4.js3
-rw-r--r--jstests/core/group5.js3
-rw-r--r--jstests/core/group6.js4
-rw-r--r--jstests/core/group8.js4
-rw-r--r--jstests/core/group9.js4
-rw-r--r--jstests/core/hashindex1.js4
-rw-r--r--jstests/core/in5.js3
-rw-r--r--jstests/core/inc-SERVER-7446.js5
-rw-r--r--jstests/core/inc3.js4
-rw-r--r--jstests/core/index3.js4
-rw-r--r--jstests/core/index4.js4
-rw-r--r--jstests/core/index8.js4
-rw-r--r--jstests/core/index9.js4
-rw-r--r--jstests/core/index_arr1.js4
-rw-r--r--jstests/core/index_big1.js4
-rw-r--r--jstests/core/index_bigkeys.js3
-rw-r--r--jstests/core/index_decimal.js5
-rw-r--r--jstests/core/index_dropdups_ignore.js4
-rw-r--r--jstests/core/index_filter_commands.js4
-rw-r--r--jstests/core/index_id_options.js4
-rw-r--r--jstests/core/index_many.js4
-rw-r--r--jstests/core/index_many2.js3
-rw-r--r--jstests/core/index_multiple_compatibility.js4
-rw-r--r--jstests/core/index_partial_create_drop.js4
-rw-r--r--jstests/core/index_partial_read_ops.js4
-rw-r--r--jstests/core/index_sparse1.js3
-rw-r--r--jstests/core/index_sparse2.js4
-rw-r--r--jstests/core/index_stats.js5
-rw-r--r--jstests/core/index_type_change.js5
-rw-r--r--jstests/core/indexa.js4
-rw-r--r--jstests/core/indexapi.js3
-rw-r--r--jstests/core/indexb.js4
-rw-r--r--jstests/core/indexes_multiple_commands.js4
-rw-r--r--jstests/core/insert2.js4
-rw-r--r--jstests/core/insert_id_undefined.js4
-rw-r--r--jstests/core/js3.js3
-rw-r--r--jstests/core/js9.js4
-rw-r--r--jstests/core/list_collections1.js4
-rw-r--r--jstests/core/list_indexes.js4
-rw-r--r--jstests/core/list_indexes_invalid.js68
-rw-r--r--jstests/core/list_indexes_invalidation.js4
-rw-r--r--jstests/core/mr2.js4
-rw-r--r--jstests/core/mr_bigobject_replace.js4
-rw-r--r--jstests/core/mr_errorhandling.js3
-rw-r--r--jstests/core/mr_killop.js5
-rw-r--r--jstests/core/mr_merge.js3
-rw-r--r--jstests/core/mr_merge2.js3
-rw-r--r--jstests/core/mr_outreduce.js3
-rw-r--r--jstests/core/mr_outreduce2.js3
-rw-r--r--jstests/core/mr_sort.js3
-rw-r--r--jstests/core/multikey_geonear.js4
-rw-r--r--jstests/core/or4.js4
-rw-r--r--jstests/core/projection_dotted_paths.js4
-rw-r--r--jstests/core/pull.js5
-rw-r--r--jstests/core/pull2.js4
-rw-r--r--jstests/core/pull_or.js4
-rw-r--r--jstests/core/pull_remove1.js4
-rw-r--r--jstests/core/pullall.js5
-rw-r--r--jstests/core/pullall2.js4
-rw-r--r--jstests/core/pushall.js5
-rw-r--r--jstests/core/remove8.js3
-rw-r--r--jstests/core/remove_justone.js4
-rw-r--r--jstests/core/return_key.js5
-rw-r--r--jstests/core/server1470.js4
-rw-r--r--jstests/core/set3.js4
-rw-r--r--jstests/core/set4.js4
-rw-r--r--jstests/core/set5.js4
-rw-r--r--jstests/core/set6.js4
-rw-r--r--jstests/core/set7.js5
-rw-r--r--jstests/core/set_type_change.js5
-rw-r--r--jstests/core/shell_writeconcern.js5
-rw-r--r--jstests/core/sortg.js4
-rw-r--r--jstests/core/splitvector.js4
-rw-r--r--jstests/core/uniqueness.js4
-rw-r--r--jstests/core/unset2.js5
-rw-r--r--jstests/core/update2.js5
-rw-r--r--jstests/core/update3.js5
-rw-r--r--jstests/core/update5.js4
-rw-r--r--jstests/core/update6.js4
-rw-r--r--jstests/core/update7.js4
-rw-r--r--jstests/core/update_addToSet.js4
-rw-r--r--jstests/core/update_arraymatch1.js4
-rw-r--r--jstests/core/update_arraymatch4.js4
-rw-r--r--jstests/core/update_arraymatch6.js5
-rw-r--r--jstests/core/update_arraymatch7.js5
-rw-r--r--jstests/core/update_arraymatch8.js5
-rw-r--r--jstests/core/update_bit_examples.js5
-rw-r--r--jstests/core/update_blank1.js4
-rw-r--r--jstests/core/update_currentdate_examples.js5
-rw-r--r--jstests/core/update_dbref.js5
-rw-r--r--jstests/core/update_mul_examples.js5
-rw-r--r--jstests/core/updatea.js4
-rw-r--r--jstests/core/updateb.js4
-rw-r--r--jstests/core/updated.js4
-rw-r--r--jstests/core/updatee.js5
-rw-r--r--jstests/core/updateg.js5
-rw-r--r--jstests/core/updateh.js5
-rw-r--r--jstests/core/updatei.js5
-rw-r--r--jstests/core/updatek.js5
-rw-r--r--jstests/core/updatem.js5
-rw-r--r--jstests/core/upsert_and.js5
-rw-r--r--jstests/core/upsert_fields.js5
-rw-r--r--jstests/core/upsert_shell.js5
-rw-r--r--jstests/core/verify_update_mods.js5
-rw-r--r--jstests/core/write_result.js5
-rw-r--r--jstests/libs/override_methods/implicitly_shard_accessed_collections.js44
246 files changed, 58 insertions, 1080 deletions
diff --git a/jstests/aggregation/bugs/ifnull.js b/jstests/aggregation/bugs/ifnull.js
index e99fcc88d26..8967ffe7ab7 100644
--- a/jstests/aggregation/bugs/ifnull.js
+++ b/jstests/aggregation/bugs/ifnull.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// $ifNull returns the result of the first expression if not null or undefined, otherwise of the
// second expression.
load('jstests/aggregation/extras/utils.js');
diff --git a/jstests/aggregation/bugs/server21632.js b/jstests/aggregation/bugs/server21632.js
index 944ca114ab6..c99834c6f73 100644
--- a/jstests/aggregation/bugs/server21632.js
+++ b/jstests/aggregation/bugs/server21632.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because the coll.stats() output from a mongod when
-// run against a sharded collection is wrapped in a "shards" object with keys for each shard.
-// @tags: [assumes_unsharded_collection]
-
// This test is designed to stress $sample, and any optimizations a storage engine might provide.
//
// A $sample stage as the first stage in a pipeline should ideally have a uniform distribution, so
@@ -30,7 +26,6 @@
// as a supported file type. (See: WT-2403 for details on forthcoming changes)
var storageEngine = jsTest.options().storageEngine || "wiredTiger";
-
if (storageEngine == "wiredTiger" && coll.stats().wiredTiger.type == 'lsm') {
return;
}
diff --git a/jstests/aggregation/bugs/server22093.js b/jstests/aggregation/bugs/server22093.js
index b47d268cfa4..ff8fda9c666 100644
--- a/jstests/aggregation/bugs/server22093.js
+++ b/jstests/aggregation/bugs/server22093.js
@@ -2,12 +2,9 @@
// from the input documents will tell the query planner to use a count scan, which is faster than an
// index scan. In this test file, we check this behavior through explain().
//
-// Cannot implicitly shard accessed collections because the explain output from a mongod when run
-// against a sharded collection is wrapped in a "shards" object with keys for each shard.
-//
// This test assumes that an initial $match will be absorbed by the query system, which will not
// happen if the $match is wrapped within a $facet stage.
-// @tags: [do_not_wrap_aggregations_in_facets,assumes_unsharded_collection]
+// @tags: [do_not_wrap_aggregations_in_facets]
load('jstests/libs/analyze_plan.js');
(function() {
diff --git a/jstests/aggregation/bugs/server3253.js b/jstests/aggregation/bugs/server3253.js
index dcff3da3033..774712ecb2f 100644
--- a/jstests/aggregation/bugs/server3253.js
+++ b/jstests/aggregation/bugs/server3253.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// for output collection of aggregation pipeline.
-// @tags: [assumes_unsharded_collection]
-
// server-3253 Unsharded support for $out
load('jstests/aggregation/extras/utils.js');
diff --git a/jstests/aggregation/bugs/server6192_server6193.js b/jstests/aggregation/bugs/server6192_server6193.js
index 9b74bdb3b4d..8a3a5eb04ee 100644
--- a/jstests/aggregation/bugs/server6192_server6193.js
+++ b/jstests/aggregation/bugs/server6192_server6193.js
@@ -1,12 +1,9 @@
// test short-circuiting of $and and $or in
// $project stages to a $const boolean
//
-// Cannot implicitly shard accessed collections because the explain output from a mongod when run
-// against a sharded collection is wrapped in a "shards" object with keys for each shard.
-//
// This test makes assumptions about how the explain output will be formatted, so cannot be
// transformed to be put inside a $facet stage.
-// @tags: [do_not_wrap_aggregations_in_facets,assumes_unsharded_collection]
+// @tags: [do_not_wrap_aggregations_in_facets]
var t = db.jstests_aggregation_server6192;
t.drop();
diff --git a/jstests/aggregation/expressions/collation_expressions.js b/jstests/aggregation/expressions/collation_expressions.js
index 93f2ada0197..99b6cb30105 100644
--- a/jstests/aggregation/expressions/collation_expressions.js
+++ b/jstests/aggregation/expressions/collation_expressions.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Test that expressions which make can make string comparisons respect the collation.
(function() {
"use strict";
diff --git a/jstests/aggregation/sources/bucket/collation_bucket.js b/jstests/aggregation/sources/bucket/collation_bucket.js
index 45f15402499..b21ae778569 100644
--- a/jstests/aggregation/sources/bucket/collation_bucket.js
+++ b/jstests/aggregation/sources/bucket/collation_bucket.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Test that the $bucket stage defines and sorts buckets according to the collation.
(function() {
"use strict";
diff --git a/jstests/aggregation/sources/bucketauto/collation_bucketauto.js b/jstests/aggregation/sources/bucketauto/collation_bucketauto.js
index 4aafa6ea511..ded4ee1316d 100644
--- a/jstests/aggregation/sources/bucketauto/collation_bucketauto.js
+++ b/jstests/aggregation/sources/bucketauto/collation_bucketauto.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Test that the $bucketAuto stage defines and sorts buckets according to the collation.
(function() {
"use strict";
diff --git a/jstests/aggregation/sources/facet/inner_graphlookup.js b/jstests/aggregation/sources/facet/inner_graphlookup.js
index 870bb975a8a..42d10149240 100644
--- a/jstests/aggregation/sources/facet/inner_graphlookup.js
+++ b/jstests/aggregation/sources/facet/inner_graphlookup.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// for target collection of $lookup and $graphLookup.
-// @tags: [assumes_unsharded_collection]
-
/**
* Tests that using a $graphLookup stage inside of a $facet stage will yield the same results as
* using the $graphLookup stage outside of the $facet stage.
diff --git a/jstests/aggregation/sources/facet/inner_lookup.js b/jstests/aggregation/sources/facet/inner_lookup.js
index c53bfa2b48e..f4890324b65 100644
--- a/jstests/aggregation/sources/facet/inner_lookup.js
+++ b/jstests/aggregation/sources/facet/inner_lookup.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// for target collection of $lookup and $graphLookup.
-// @tags: [assumes_unsharded_collection]
-
/**
* Tests that using a $lookup stage inside of a $facet stage will yield the same results as using
* the $lookup stage outside of the $facet stage.
diff --git a/jstests/aggregation/sources/geonear/collation_geonear.js b/jstests/aggregation/sources/geonear/collation_geonear.js
index 076e0a8bea8..38a20d847b7 100644
--- a/jstests/aggregation/sources/geonear/collation_geonear.js
+++ b/jstests/aggregation/sources/geonear/collation_geonear.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Test that the $geoNear stage's query predicate respects the collation.
(function() {
"use strict";
diff --git a/jstests/aggregation/sources/graphLookup/airports.js b/jstests/aggregation/sources/graphLookup/airports.js
index 9254fd992fa..71a38e268b8 100644
--- a/jstests/aggregation/sources/graphLookup/airports.js
+++ b/jstests/aggregation/sources/graphLookup/airports.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// for target collection of $lookup and $graphLookup.
-// @tags: [assumes_unsharded_collection]
-
// In MongoDB 3.4, $graphLookup was introduced. In this file, we test some complex graphs.
(function() {
diff --git a/jstests/aggregation/sources/graphLookup/basic.js b/jstests/aggregation/sources/graphLookup/basic.js
index c0bcb1a8a53..63b2a63f95a 100644
--- a/jstests/aggregation/sources/graphLookup/basic.js
+++ b/jstests/aggregation/sources/graphLookup/basic.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// for target collection of $lookup and $graphLookup.
-// @tags: [assumes_unsharded_collection]
-
// In MongoDB 3.4, $graphLookup was introduced. In this file, we test basic behavior and correctness
// of the stage.
diff --git a/jstests/aggregation/sources/graphLookup/collation_graphlookup.js b/jstests/aggregation/sources/graphLookup/collation_graphlookup.js
index 7b457289cc6..833b2f2d771 100644
--- a/jstests/aggregation/sources/graphLookup/collation_graphlookup.js
+++ b/jstests/aggregation/sources/graphLookup/collation_graphlookup.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// for target collection of $lookup and $graphLookup.
-// @tags: [assumes_unsharded_collection]
-
/**
* Tests that the $graphLookup stage respects the collation when matching between the
* 'connectFromField' and the 'connectToField'. $graphLookup should use the collation
diff --git a/jstests/aggregation/sources/graphLookup/error.js b/jstests/aggregation/sources/graphLookup/error.js
index 6e050105782..a686fb30945 100644
--- a/jstests/aggregation/sources/graphLookup/error.js
+++ b/jstests/aggregation/sources/graphLookup/error.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// for target collection of $lookup and $graphLookup.
-// @tags: [assumes_unsharded_collection]
-
// In MongoDB 3.4, $graphLookup was introduced. In this file, we test the error cases.
load("jstests/aggregation/extras/utils.js"); // For "assertErrorCode".
diff --git a/jstests/aggregation/sources/graphLookup/filter.js b/jstests/aggregation/sources/graphLookup/filter.js
index 15ff6d4a4ae..edf1deda331 100644
--- a/jstests/aggregation/sources/graphLookup/filter.js
+++ b/jstests/aggregation/sources/graphLookup/filter.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// for target collection of $lookup and $graphLookup.
-// @tags: [assumes_unsharded_collection]
-
// In SERVER-24714, the 'restrictSearchWithMatch' option was added to $graphLookup. In this file,
// we test the functionality and correctness of the option.
diff --git a/jstests/aggregation/sources/graphLookup/nested_objects.js b/jstests/aggregation/sources/graphLookup/nested_objects.js
index d40cced2ac4..b2e3f5ac59a 100644
--- a/jstests/aggregation/sources/graphLookup/nested_objects.js
+++ b/jstests/aggregation/sources/graphLookup/nested_objects.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// for target collection of $lookup and $graphLookup.
-// @tags: [assumes_unsharded_collection]
-
// In MongoDB 3.4, $graphLookup was introduced. In this file, we test the behavior of graphLookup
// when the 'connectToField' is a nested array, or when the 'connectFromField' is a nested array.
diff --git a/jstests/aggregation/sources/graphLookup/socialite.js b/jstests/aggregation/sources/graphLookup/socialite.js
index 228c0f56c0e..6efe2672540 100644
--- a/jstests/aggregation/sources/graphLookup/socialite.js
+++ b/jstests/aggregation/sources/graphLookup/socialite.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// for target collection of $lookup and $graphLookup.
-// @tags: [assumes_unsharded_collection]
-
// In MongoDB 3.4, $graphLookup was introduced. In this file, we test $graphLookup as applied to the
// Socialite schema example available here: https://github.com/mongodb-labs/socialite
diff --git a/jstests/aggregation/sources/group/collation_group.js b/jstests/aggregation/sources/group/collation_group.js
index c4977900078..4bf02ee5c97 100644
--- a/jstests/aggregation/sources/group/collation_group.js
+++ b/jstests/aggregation/sources/group/collation_group.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Test that the $group stage and all accumulators respect the collation.
(function() {
"use strict";
diff --git a/jstests/aggregation/sources/lookup/collation_lookup.js b/jstests/aggregation/sources/lookup/collation_lookup.js
index 89a0b21c038..cf1b742c367 100644
--- a/jstests/aggregation/sources/lookup/collation_lookup.js
+++ b/jstests/aggregation/sources/lookup/collation_lookup.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
/**
* Tests that the $lookup stage respects the collation.
*
diff --git a/jstests/aggregation/sources/match/collation_match.js b/jstests/aggregation/sources/match/collation_match.js
index bc9456898f9..7136e03f9da 100644
--- a/jstests/aggregation/sources/match/collation_match.js
+++ b/jstests/aggregation/sources/match/collation_match.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Test that the $match stage respects the collation.
(function() {
"use strict";
diff --git a/jstests/aggregation/sources/redact/collation_redact.js b/jstests/aggregation/sources/redact/collation_redact.js
index 36304e9a7f2..d990c78959a 100644
--- a/jstests/aggregation/sources/redact/collation_redact.js
+++ b/jstests/aggregation/sources/redact/collation_redact.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Test that the $redact stage respects the collation.
(function() {
"use strict";
diff --git a/jstests/core/agg_hint.js b/jstests/core/agg_hint.js
index e578448d4d6..a73e2593936 100644
--- a/jstests/core/agg_hint.js
+++ b/jstests/core/agg_hint.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Confirms correct behavior for hinted aggregation execution. This includes tests for scenarios
// where agg execution differs from query. It also includes confirmation that hint works for find
// command against views, which is converted to a hinted aggregation on execution.
diff --git a/jstests/core/and2.js b/jstests/core/and2.js
index 5a946c2cb76..a794268130b 100644
--- a/jstests/core/and2.js
+++ b/jstests/core/and2.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Test dollar sign operator with $and SERVER-1089
t = db.jstests_and2;
diff --git a/jstests/core/autoid.js b/jstests/core/autoid.js
index 679b109fcc5..f4707e5fe65 100644
--- a/jstests/core/autoid.js
+++ b/jstests/core/autoid.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
f = db.jstests_autoid;
f.drop();
diff --git a/jstests/core/batch_write_collation_estsize.js b/jstests/core/batch_write_collation_estsize.js
index 594517da9f9..944b2094696 100644
--- a/jstests/core/batch_write_collation_estsize.js
+++ b/jstests/core/batch_write_collation_estsize.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Tests that the update and delete batch write operations account for the size of the collation
// specification in the write operation document.
diff --git a/jstests/core/batch_write_command_delete.js b/jstests/core/batch_write_command_delete.js
index b11b4f192d2..232fa1839a1 100644
--- a/jstests/core/batch_write_command_delete.js
+++ b/jstests/core/batch_write_command_delete.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
//
// Ensures that mongod respects the batch write protocols for delete
//
diff --git a/jstests/core/batch_write_command_insert.js b/jstests/core/batch_write_command_insert.js
index 0997109736b..afbe0eed0ff 100644
--- a/jstests/core/batch_write_command_insert.js
+++ b/jstests/core/batch_write_command_insert.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of not being able to create unique index
-// using hashed shard key pattern.
-// @tags: [cannot_create_unique_index_when_using_hashed_shard_key]
-
//
// Ensures that mongod respects the batch write protocol for inserts
//
diff --git a/jstests/core/batch_write_command_update.js b/jstests/core/batch_write_command_update.js
index 3ac6201cce5..ead2275399c 100644
--- a/jstests/core/batch_write_command_update.js
+++ b/jstests/core/batch_write_command_update.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
//
// Ensures that mongod respects the batch write protocols for updates
//
diff --git a/jstests/core/bench_test1.js b/jstests/core/bench_test1.js
index 2f35be513fc..d29a0d577e7 100644
--- a/jstests/core/bench_test1.js
+++ b/jstests/core/bench_test1.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
t = db.bench_test1;
t.drop();
diff --git a/jstests/core/bulk_api_ordered.js b/jstests/core/bulk_api_ordered.js
index 4efdd7c319b..a880cdb630e 100644
--- a/jstests/core/bulk_api_ordered.js
+++ b/jstests/core/bulk_api_ordered.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
var collectionName = "bulk_api_ordered";
var coll = db.getCollection(collectionName);
diff --git a/jstests/core/bulk_api_unordered.js b/jstests/core/bulk_api_unordered.js
index 8e2ca7a7157..6720e644e47 100644
--- a/jstests/core/bulk_api_unordered.js
+++ b/jstests/core/bulk_api_unordered.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
var collectionName = "bulk_api_unordered";
var coll = db.getCollection(collectionName);
coll.drop();
diff --git a/jstests/core/bulk_insert_capped.js b/jstests/core/bulk_insert_capped.js
index a54b94c5022..b7d21cee3f5 100644
--- a/jstests/core/bulk_insert_capped.js
+++ b/jstests/core/bulk_insert_capped.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// SERVER-21488 Test that multi inserts into capped collections don't cause corruption.
// Note: this file must have a name that starts with "bulk" so it gets run by bulk_gle_passthrough.
(function() {
diff --git a/jstests/core/collation.js b/jstests/core/collation.js
index f73ea604650..51bec0f8bce 100644
--- a/jstests/core/collation.js
+++ b/jstests/core/collation.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Integration tests for the collation feature.
(function() {
'use strict';
diff --git a/jstests/core/collation_update.js b/jstests/core/collation_update.js
index a48e9c85d1a..15d205c9984 100644
--- a/jstests/core/collation_update.js
+++ b/jstests/core/collation_update.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Integration tests for collation-aware updates.
(function() {
'use strict';
diff --git a/jstests/core/collmod.js b/jstests/core/collmod.js
index 8ed2ee503e4..16f9694560c 100644
--- a/jstests/core/collmod.js
+++ b/jstests/core/collmod.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Basic js tests for the collMod command.
// Test setting the usePowerOf2Sizes flag, and modifying TTL indexes.
diff --git a/jstests/core/collmod_bad_spec.js b/jstests/core/collmod_bad_spec.js
index 0402a248f30..ccce81fd4b1 100644
--- a/jstests/core/collmod_bad_spec.js
+++ b/jstests/core/collmod_bad_spec.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// This is a regression test for SERVER-21545.
//
// Tests that a collMod with a bad specification does not cause any changes, and does not crash the
diff --git a/jstests/core/commands_namespace_parsing.js b/jstests/core/commands_namespace_parsing.js
index 9f5fd2ffe26..c5e6cd3a285 100644
--- a/jstests/core/commands_namespace_parsing.js
+++ b/jstests/core/commands_namespace_parsing.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because the error response from the shard about
-// using the empty string as the out collection name is converted to an error and no longer retains
-// the "code" property.
-// @tags: [assumes_unsharded_collection]
-
// This file tests that commands namespace parsing rejects embedded null bytes.
// Note that for each command, a properly formatted command object must be passed to the helper
// function, regardless of the namespace used in the command object.
diff --git a/jstests/core/count11.js b/jstests/core/count11.js
index 1a9c89f3357..aeda1e4b1cf 100644
--- a/jstests/core/count11.js
+++ b/jstests/core/count11.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// SERVER-8514: Test the count command returns an error to the user when given an invalid query
// predicate, even when the collection doesn't exist.
diff --git a/jstests/core/coveredIndex1.js b/jstests/core/coveredIndex1.js
index 1e982f0a8ea..328c53ba0bc 100644
--- a/jstests/core/coveredIndex1.js
+++ b/jstests/core/coveredIndex1.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because queries on a sharded collection are not
-// able to be covered when they aren't on the shard key since the document needs to be fetched in
-// order to apply the SHARDING_FILTER stage.
-// @tags: [assumes_unsharded_collection]
t = db["jstests_coveredIndex1"];
t.drop();
diff --git a/jstests/core/coveredIndex2.js b/jstests/core/coveredIndex2.js
index 058b739fba2..f7b542008f3 100644
--- a/jstests/core/coveredIndex2.js
+++ b/jstests/core/coveredIndex2.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because queries on a sharded collection are not
-// able to be covered when they aren't on the shard key since the document needs to be fetched in
-// order to apply the SHARDING_FILTER stage.
-// @tags: [assumes_unsharded_collection]
-
t = db["jstests_coveredIndex2"];
t.drop();
diff --git a/jstests/core/covered_index_compound_1.js b/jstests/core/covered_index_compound_1.js
index ba2c9b6ecc5..45f17fd7d44 100644
--- a/jstests/core/covered_index_compound_1.js
+++ b/jstests/core/covered_index_compound_1.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because queries on a sharded collection are not
-// able to be covered when they aren't on the shard key since the document needs to be fetched in
-// order to apply the SHARDING_FILTER stage.
-// @tags: [assumes_unsharded_collection]
-
// Compound index covered query tests
// Include helpers for analyzing explain output.
diff --git a/jstests/core/covered_index_simple_1.js b/jstests/core/covered_index_simple_1.js
index b9e33f650dd..3827ef4acfc 100644
--- a/jstests/core/covered_index_simple_1.js
+++ b/jstests/core/covered_index_simple_1.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because queries on a sharded collection are not
-// able to be covered when they aren't on the shard key since the document needs to be fetched in
-// order to apply the SHARDING_FILTER stage.
-// @tags: [assumes_unsharded_collection]
-
// Simple covered index query test
// Include helpers for analyzing explain output.
diff --git a/jstests/core/covered_index_simple_2.js b/jstests/core/covered_index_simple_2.js
index 0974ee0eb50..0c947849703 100644
--- a/jstests/core/covered_index_simple_2.js
+++ b/jstests/core/covered_index_simple_2.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because queries on a sharded collection are not
-// able to be covered when they aren't on the shard key since the document needs to be fetched in
-// order to apply the SHARDING_FILTER stage.
-// @tags: [assumes_unsharded_collection]
-
// Simple covered index query test with unique index
// Include helpers for analyzing explain output.
diff --git a/jstests/core/covered_index_simple_3.js b/jstests/core/covered_index_simple_3.js
index 7d021a17ca8..e445396c4c8 100644
--- a/jstests/core/covered_index_simple_3.js
+++ b/jstests/core/covered_index_simple_3.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because queries on a sharded collection are not
-// able to be covered when they aren't on the shard key since the document needs to be fetched in
-// order to apply the SHARDING_FILTER stage.
-// @tags: [assumes_unsharded_collection]
-
// Simple covered index query test with a unique sparse index
// Include helpers for analyzing explain output.
diff --git a/jstests/core/covered_index_sort_1.js b/jstests/core/covered_index_sort_1.js
index a65cc415ea4..a5984a34f19 100644
--- a/jstests/core/covered_index_sort_1.js
+++ b/jstests/core/covered_index_sort_1.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because queries on a sharded collection are not
-// able to be covered when they aren't on the shard key since the document needs to be fetched in
-// order to apply the SHARDING_FILTER stage.
-// @tags: [assumes_unsharded_collection]
-
// Simple covered index query test with sort
// Include helpers for analyzing explain output.
diff --git a/jstests/core/covered_index_sort_3.js b/jstests/core/covered_index_sort_3.js
index b93b25f02a3..1c98fb69be4 100644
--- a/jstests/core/covered_index_sort_3.js
+++ b/jstests/core/covered_index_sort_3.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because queries on a sharded collection are not
-// able to be covered when they aren't on the shard key since the document needs to be fetched in
-// order to apply the SHARDING_FILTER stage.
-// @tags: [assumes_unsharded_collection]
-
// Compound index covered query tests with sort
// Include helpers for analyzing explain output.
diff --git a/jstests/core/covered_multikey.js b/jstests/core/covered_multikey.js
index db1aaf9c525..ebffcafbe23 100644
--- a/jstests/core/covered_multikey.js
+++ b/jstests/core/covered_multikey.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because queries on a sharded collection are not
-// able to be covered when they aren't on the shard key since the document needs to be fetched in
-// order to apply the SHARDING_FILTER stage.
-// @tags: [assumes_unsharded_collection]
-
/**
* Test covering behavior for queries over a multikey index.
*/
diff --git a/jstests/core/create_collection.js b/jstests/core/create_collection.js
index 2ebbd4c0335..2af8bc721a2 100644
--- a/jstests/core/create_collection.js
+++ b/jstests/core/create_collection.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Tests for the "create" command.
(function() {
"use strict";
diff --git a/jstests/core/crud_api.js b/jstests/core/crud_api.js
index abf40389a43..c9dbfb40c85 100644
--- a/jstests/core/crud_api.js
+++ b/jstests/core/crud_api.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
(function() {
"use strict";
diff --git a/jstests/core/datasize2.js b/jstests/core/datasize2.js
index a64bb62c287..eb79b12a6c4 100644
--- a/jstests/core/datasize2.js
+++ b/jstests/core/datasize2.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because the "dataSize" command returns an
-// "keyPattern must equal shard key" error response.
-// @tags: [assumes_unsharded_collection]
-
//
// Test dataSize command, when called on the same or different database
// than the collection being queried.
diff --git a/jstests/core/doc_validation.js b/jstests/core/doc_validation.js
index 7a3dc5f038d..a30763869e7 100644
--- a/jstests/core/doc_validation.js
+++ b/jstests/core/doc_validation.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Test basic inserts and updates with document validation.
(function() {
"use strict";
diff --git a/jstests/core/doc_validation_invalid_validators.js b/jstests/core/doc_validation_invalid_validators.js
index 45cfa7c2cf4..b78b31c0977 100644
--- a/jstests/core/doc_validation_invalid_validators.js
+++ b/jstests/core/doc_validation_invalid_validators.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Verify invalid validator statements won't work and that we
// can't create validated collections on restricted databases.
(function() {
diff --git a/jstests/core/doc_validation_options.js b/jstests/core/doc_validation_options.js
index 8e4f34c3602..8a96685e48f 100644
--- a/jstests/core/doc_validation_options.js
+++ b/jstests/core/doc_validation_options.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
(function() {
"use strict";
diff --git a/jstests/core/drop.js b/jstests/core/drop.js
index 789c87bf227..22ed97ad805 100644
--- a/jstests/core/drop.js
+++ b/jstests/core/drop.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
var coll = db.jstests_drop;
coll.drop();
diff --git a/jstests/core/drop_index.js b/jstests/core/drop_index.js
index cf333cf738c..f2e99baa8f8 100644
--- a/jstests/core/drop_index.js
+++ b/jstests/core/drop_index.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
t = db.dropIndex;
t.drop();
diff --git a/jstests/core/ensure_sorted.js b/jstests/core/ensure_sorted.js
index 13c48708aff..c3d8f075f5d 100644
--- a/jstests/core/ensure_sorted.js
+++ b/jstests/core/ensure_sorted.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// SERVER-17011 Tests whether queries which specify sort and batch size can generate results out of
// order due to the ntoreturn hack. The EnsureSortedStage should solve this problem.
(function() {
diff --git a/jstests/core/eval2.js b/jstests/core/eval2.js
index 6c0fc1f58e9..598314a6c5b 100644
--- a/jstests/core/eval2.js
+++ b/jstests/core/eval2.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of unsupported group operator on sharded
-// collection.
-// @tags: [assumes_unsharded_collection]
t = db.eval2;
t.drop();
diff --git a/jstests/core/eval3.js b/jstests/core/eval3.js
index 8cdd3723977..c4f8be21056 100644
--- a/jstests/core/eval3.js
+++ b/jstests/core/eval3.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// from db.eval.
-// @tags: [assumes_unsharded_collection]
t = db.eval3;
t.drop();
diff --git a/jstests/core/eval4.js b/jstests/core/eval4.js
index b67aa4b4445..0d120b393de 100644
--- a/jstests/core/eval4.js
+++ b/jstests/core/eval4.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// from db.eval.
-// @tags: [assumes_unsharded_collection]
t = db.eval4;
t.drop();
diff --git a/jstests/core/eval_mr.js b/jstests/core/eval_mr.js
index 04de66affb0..4a3dc8dad6c 100644
--- a/jstests/core/eval_mr.js
+++ b/jstests/core/eval_mr.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: Cannot output to a
-// non-sharded collection because sharded collection exists already.
-// @tags: [assumes_unsharded_collection]
-
// Test that the eval command can't be used to invoke the mapReduce command. SERVER-17889.
(function() {
"use strict";
diff --git a/jstests/core/evald.js b/jstests/core/evald.js
index bc381d7314c..8049d2ba8ae 100644
--- a/jstests/core/evald.js
+++ b/jstests/core/evald.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// from db.eval.
-// @tags: [assumes_unsharded_collection]
-
t = db.jstests_evald;
t.drop();
diff --git a/jstests/core/explain_agg_write_concern.js b/jstests/core/explain_agg_write_concern.js
index 7a73bee79cf..3a70040a525 100644
--- a/jstests/core/explain_agg_write_concern.js
+++ b/jstests/core/explain_agg_write_concern.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// for output collection of aggregation pipeline.
-// @tags: [assumes_unsharded_collection]
-
/**
* Tests related to the aggregate commands behavior with writeConcern and writeConcern + explain.
*/
diff --git a/jstests/core/explain_distinct.js b/jstests/core/explain_distinct.js
index 4cc9eab4eab..6fd0a012205 100644
--- a/jstests/core/explain_distinct.js
+++ b/jstests/core/explain_distinct.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
/**
* This test ensures that explain on the distinct command works.
*/
diff --git a/jstests/core/explain_find_and_modify.js b/jstests/core/explain_find_and_modify.js
index 3c061084962..1d30486ecb4 100644
--- a/jstests/core/explain_find_and_modify.js
+++ b/jstests/core/explain_find_and_modify.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
/**
* Test correctness of explaining findAndModify. Asserts the following:
*
diff --git a/jstests/core/explain_missing_collection.js b/jstests/core/explain_missing_collection.js
index 458b15c6a80..0d1eae844f8 100644
--- a/jstests/core/explain_missing_collection.js
+++ b/jstests/core/explain_missing_collection.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of unsupported group operator on sharded
-// collection.
-// @tags: [assumes_unsharded_collection]
-
// Test explain of various operations against a non-existent collection
(function() {
var missingColl = db.explain_null_collection;
diff --git a/jstests/core/explain_multi_plan.js b/jstests/core/explain_multi_plan.js
index a41a4f0e67b..693237d9edc 100644
--- a/jstests/core/explain_multi_plan.js
+++ b/jstests/core/explain_multi_plan.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
/**
* Tests running explain on a variety of explainable commands (find, update, remove, etc.) when
* there are multiple plans available. This is a regression test for SERVER-20849 and SERVER-21376.
diff --git a/jstests/core/explain_shell_helpers.js b/jstests/core/explain_shell_helpers.js
index cfeb9451567..b5f50437304 100644
--- a/jstests/core/explain_shell_helpers.js
+++ b/jstests/core/explain_shell_helpers.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because the explain output from a mongod when run
-// against a sharded collection is wrapped in a "shards" object with keys for each shard.
-// @tags: [assumes_unsharded_collection]
-
// Tests for the .explain() shell helper, which provides syntactic sugar for the explain command.
var t = db.jstests_explain_helpers;
diff --git a/jstests/core/explain_upsert.js b/jstests/core/explain_upsert.js
index aab8758366a..1ac254291f1 100644
--- a/jstests/core/explain_upsert.js
+++ b/jstests/core/explain_upsert.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Test explain for {upsert: true} updates.
var t = db.jstests_explain_upsert;
diff --git a/jstests/core/filemd5.js b/jstests/core/filemd5.js
index cbcdfe6b3dc..b43dccf7036 100644
--- a/jstests/core/filemd5.js
+++ b/jstests/core/filemd5.js
@@ -1,13 +1,10 @@
-// Cannot implicitly shard accessed collections because of following error: GridFS fs.chunks
-// collection must be sharded on either {files_id:1} or {files_id:1, n:1}
-// @tags: [assumes_unsharded_collection]
-
-db.fs.chunks.drop();
-db.fs.chunks.insert({files_id: 1, n: 0, data: new BinData(0, "test")});
-
-x = db.runCommand({"filemd5": 1, "root": "fs"});
-assert(!x.ok, tojson(x));
-
-db.fs.chunks.ensureIndex({files_id: 1, n: 1});
-x = db.runCommand({"filemd5": 1, "root": "fs"});
-assert(x.ok, tojson(x));
+
+db.fs.chunks.drop();
+db.fs.chunks.insert({files_id: 1, n: 0, data: new BinData(0, "test")});
+
+x = db.runCommand({"filemd5": 1, "root": "fs"});
+assert(!x.ok, tojson(x));
+
+db.fs.chunks.ensureIndex({files_id: 1, n: 1});
+x = db.runCommand({"filemd5": 1, "root": "fs"});
+assert(x.ok, tojson(x));
diff --git a/jstests/core/find_and_modify.js b/jstests/core/find_and_modify.js
index e86ba4eec31..394b618f109 100644
--- a/jstests/core/find_and_modify.js
+++ b/jstests/core/find_and_modify.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
t = db.find_and_modify;
t.drop();
diff --git a/jstests/core/find_and_modify2.js b/jstests/core/find_and_modify2.js
index a73dcb5fda5..e9bc8f5b23a 100644
--- a/jstests/core/find_and_modify2.js
+++ b/jstests/core/find_and_modify2.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
t = db.find_and_modify2;
t.drop();
diff --git a/jstests/core/find_and_modify3.js b/jstests/core/find_and_modify3.js
index 3f8fc22d98d..a1a88aeecb5 100644
--- a/jstests/core/find_and_modify3.js
+++ b/jstests/core/find_and_modify3.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
t = db.find_and_modify3;
t.drop();
diff --git a/jstests/core/find_and_modify4.js b/jstests/core/find_and_modify4.js
index 0c6942ab055..b6be565b70a 100644
--- a/jstests/core/find_and_modify4.js
+++ b/jstests/core/find_and_modify4.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
t = db.find_and_modify4;
t.drop();
diff --git a/jstests/core/find_and_modify_concurrent_update.js b/jstests/core/find_and_modify_concurrent_update.js
index ead81732ecc..3986ac62ea9 100644
--- a/jstests/core/find_and_modify_concurrent_update.js
+++ b/jstests/core/find_and_modify_concurrent_update.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Ensures that find and modify will not apply an update to a document which, due to a concurrent
// modification, no longer matches the query predicate.
(function() {
diff --git a/jstests/core/find_and_modify_empty_coll.js b/jstests/core/find_and_modify_empty_coll.js
index 7325d73583e..2d3a2ee8ffd 100644
--- a/jstests/core/find_and_modify_empty_coll.js
+++ b/jstests/core/find_and_modify_empty_coll.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
/**
* Test that findAndModify works against a non-existent collection.
*/
diff --git a/jstests/core/find_and_modify_empty_update.js b/jstests/core/find_and_modify_empty_update.js
index a9b8cb55b34..ccfb1a8201f 100644
--- a/jstests/core/find_and_modify_empty_update.js
+++ b/jstests/core/find_and_modify_empty_update.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Test passing update:{} to findAndModify. SERVER-13883.
var coll = db.find_and_modify_empty_update;
diff --git a/jstests/core/find_and_modify_server6254.js b/jstests/core/find_and_modify_server6254.js
index 1eca30e31a9..c2bfa3628a1 100644
--- a/jstests/core/find_and_modify_server6254.js
+++ b/jstests/core/find_and_modify_server6254.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.find_and_modify_server6254;
t.drop();
diff --git a/jstests/core/find_and_modify_server6582.js b/jstests/core/find_and_modify_server6582.js
index 7ad8aebee76..79a0b31d4ed 100644
--- a/jstests/core/find_and_modify_server6582.js
+++ b/jstests/core/find_and_modify_server6582.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.find_and_modify_server6582;
diff --git a/jstests/core/find_and_modify_server6588.js b/jstests/core/find_and_modify_server6588.js
index 197c892ca67..9c546daba72 100644
--- a/jstests/core/find_and_modify_server6588.js
+++ b/jstests/core/find_and_modify_server6588.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.find_and_modify_sever6588;
diff --git a/jstests/core/find_and_modify_server6659.js b/jstests/core/find_and_modify_server6659.js
index 029a32d6a49..6b3f958c0e0 100644
--- a/jstests/core/find_and_modify_server6659.js
+++ b/jstests/core/find_and_modify_server6659.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.find_and_modify_server6659;
t.drop();
diff --git a/jstests/core/find_and_modify_server6865.js b/jstests/core/find_and_modify_server6865.js
index 98e5b28ee47..3583da42412 100644
--- a/jstests/core/find_and_modify_server6865.js
+++ b/jstests/core/find_and_modify_server6865.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
/**
* Test that projection with a positional operator works with findAndModify
* when remove=true or new=false, but not when new=true.
diff --git a/jstests/core/find_and_modify_server6909.js b/jstests/core/find_and_modify_server6909.js
index c74e342822b..8e807e0c893 100644
--- a/jstests/core/find_and_modify_server6909.js
+++ b/jstests/core/find_and_modify_server6909.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
c = db.find_and_modify_server6906;
c.drop();
diff --git a/jstests/core/find_and_modify_server6993.js b/jstests/core/find_and_modify_server6993.js
index 4d9b169700d..bf8ed52c9c7 100644
--- a/jstests/core/find_and_modify_server6993.js
+++ b/jstests/core/find_and_modify_server6993.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
c = db.find_and_modify_server6993;
c.drop();
diff --git a/jstests/core/find_and_modify_server7660.js b/jstests/core/find_and_modify_server7660.js
index 7973279ddcf..d344d773dca 100644
--- a/jstests/core/find_and_modify_server7660.js
+++ b/jstests/core/find_and_modify_server7660.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.find_and_modify_server7660;
t.drop();
diff --git a/jstests/core/find_and_modify_where.js b/jstests/core/find_and_modify_where.js
index f4977c6565e..e3d5604559a 100644
--- a/jstests/core/find_and_modify_where.js
+++ b/jstests/core/find_and_modify_where.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.find_and_modify_where;
t.drop();
diff --git a/jstests/core/fts1.js b/jstests/core/fts1.js
index 5f507733b05..23364b2ecb7 100644
--- a/jstests/core/fts1.js
+++ b/jstests/core/fts1.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
load("jstests/libs/fts.js");
t = db.text1;
diff --git a/jstests/core/fts_blogwild.js b/jstests/core/fts_blogwild.js
index 82cb594bab6..377e4529f3e 100644
--- a/jstests/core/fts_blogwild.js
+++ b/jstests/core/fts_blogwild.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
t = db.text_blogwild;
t.drop();
diff --git a/jstests/core/fts_explain.js b/jstests/core/fts_explain.js
index b8c507f1a60..225be626d2c 100644
--- a/jstests/core/fts_explain.js
+++ b/jstests/core/fts_explain.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
// Test $text explain. SERVER-12037.
var coll = db.fts_explain;
diff --git a/jstests/core/fts_index.js b/jstests/core/fts_index.js
index 45ed68ce6c6..ab953a88624 100644
--- a/jstests/core/fts_index.js
+++ b/jstests/core/fts_index.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Test that:
// 1. Text indexes properly validate the index spec used to create them.
// 2. Text indexes properly enforce a schema on the language_override field.
diff --git a/jstests/core/fts_index2.js b/jstests/core/fts_index2.js
index ecae5edb3a8..fa0129acc5c 100644
--- a/jstests/core/fts_index2.js
+++ b/jstests/core/fts_index2.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because renameCollection command not supported
-// on sharded collections.
-// @tags: [assumes_unsharded_collection]
-
// Test that collections with text indexes can be renamed. SERVER-14027.
var coll1 = db.fts_index2;
diff --git a/jstests/core/fts_index3.js b/jstests/core/fts_index3.js
index 1a700b3ed7b..bb94704eaf9 100644
--- a/jstests/core/fts_index3.js
+++ b/jstests/core/fts_index3.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Test that updates to fields in a text-indexed document are correctly reflected in the text index.
var coll = db.fts_index3;
diff --git a/jstests/core/geo1.js b/jstests/core/geo1.js
index c33a5f8919c..724ae31a3ce 100644
--- a/jstests/core/geo1.js
+++ b/jstests/core/geo1.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
t = db.geo1;
t.drop();
diff --git a/jstests/core/geo10.js b/jstests/core/geo10.js
index 9b0fb42c2b5..640ae67e594 100644
--- a/jstests/core/geo10.js
+++ b/jstests/core/geo10.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
// Test for SERVER-2746
coll = db.geo10;
diff --git a/jstests/core/geo2.js b/jstests/core/geo2.js
index f4e8a5bbd54..0b7e91c18bc 100644
--- a/jstests/core/geo2.js
+++ b/jstests/core/geo2.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
t = db.geo2;
t.drop();
diff --git a/jstests/core/geo3.js b/jstests/core/geo3.js
index e12ffb6184e..feb93b783cb 100644
--- a/jstests/core/geo3.js
+++ b/jstests/core/geo3.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
t = db.geo3;
t.drop();
diff --git a/jstests/core/geo6.js b/jstests/core/geo6.js
index 6cd1ce460f3..3d681fe9b7e 100644
--- a/jstests/core/geo6.js
+++ b/jstests/core/geo6.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
t = db.geo6;
t.drop();
diff --git a/jstests/core/geo9.js b/jstests/core/geo9.js
index 598de3d2dc1..7419615818e 100644
--- a/jstests/core/geo9.js
+++ b/jstests/core/geo9.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
t = db.geo9;
t.drop();
diff --git a/jstests/core/geo_array0.js b/jstests/core/geo_array0.js
index 3b74e42e533..42b9c758e45 100644
--- a/jstests/core/geo_array0.js
+++ b/jstests/core/geo_array0.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
// Make sure the very basics of geo arrays are sane by creating a few multi location docs
t = db.geoarray;
diff --git a/jstests/core/geo_array2.js b/jstests/core/geo_array2.js
index 58d1f989a17..6195e038de3 100644
--- a/jstests/core/geo_array2.js
+++ b/jstests/core/geo_array2.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// Check the semantics of near calls with multiple locations
t = db.geoarray2;
diff --git a/jstests/core/geo_borders.js b/jstests/core/geo_borders.js
index f110d58ec00..f8a94d997dd 100644
--- a/jstests/core/geo_borders.js
+++ b/jstests/core/geo_borders.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
t = db.borders;
t.drop();
diff --git a/jstests/core/geo_center_sphere2.js b/jstests/core/geo_center_sphere2.js
index d5216509fdd..79c69de1ab4 100644
--- a/jstests/core/geo_center_sphere2.js
+++ b/jstests/core/geo_center_sphere2.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
//
// Tests the error handling of spherical queries
// along with multi-location documents.
diff --git a/jstests/core/geo_distinct.js b/jstests/core/geo_distinct.js
index 4dcc7a7f35f..33ea7dd3461 100644
--- a/jstests/core/geo_distinct.js
+++ b/jstests/core/geo_distinct.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// Tests distinct with geospatial field values.
// 1. Test distinct with geo values for 'key' (SERVER-2135)
// 2. Test distinct with geo predicates for 'query' (SERVER-13769)
diff --git a/jstests/core/geo_exactfetch.js b/jstests/core/geo_exactfetch.js
index ed117786fb2..4af4032045f 100644
--- a/jstests/core/geo_exactfetch.js
+++ b/jstests/core/geo_exactfetch.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// SERVER-7322
t = db.geo_exactfetch;
t.drop();
diff --git a/jstests/core/geo_group.js b/jstests/core/geo_group.js
index 3ce3d63ef0c..34ecc2c3a84 100644
--- a/jstests/core/geo_group.js
+++ b/jstests/core/geo_group.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
t = db.geo_group;
t.drop();
diff --git a/jstests/core/geo_max.js b/jstests/core/geo_max.js
index d8c41781bf8..03771ea34d4 100644
--- a/jstests/core/geo_max.js
+++ b/jstests/core/geo_max.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// Test where points are on _max (180)
// Using GeoNearRandom because this test needs a lot of points in the index.
// If there aren't enough points the test passes even if the code is broken.
diff --git a/jstests/core/geo_mindistance.js b/jstests/core/geo_mindistance.js
index 43efd499939..4bbb77db9bf 100644
--- a/jstests/core/geo_mindistance.js
+++ b/jstests/core/geo_mindistance.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
/* Test $minDistance option for $near and $nearSphere queries, and geoNear
* command. SERVER-9395.
*/
diff --git a/jstests/core/geo_mindistance_boundaries.js b/jstests/core/geo_mindistance_boundaries.js
index 8de431a6b14..7e97732dfd1 100644
--- a/jstests/core/geo_mindistance_boundaries.js
+++ b/jstests/core/geo_mindistance_boundaries.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
/* Test boundary conditions for $minDistance option for $near and $nearSphere
* queries. SERVER-9395.
*/
diff --git a/jstests/core/geo_multinest0.js b/jstests/core/geo_multinest0.js
index f59e61c037f..30b66b4adbb 100644
--- a/jstests/core/geo_multinest0.js
+++ b/jstests/core/geo_multinest0.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
// Make sure nesting of location arrays also works.
t = db.geonest;
diff --git a/jstests/core/geo_multinest1.js b/jstests/core/geo_multinest1.js
index fc3e0d2d4d4..78e4c38e49b 100644
--- a/jstests/core/geo_multinest1.js
+++ b/jstests/core/geo_multinest1.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
// Test distance queries with interleaved distances
t = db.multinest;
diff --git a/jstests/core/geo_near_random1.js b/jstests/core/geo_near_random1.js
index e0fb816447f..1e7f2bb587d 100644
--- a/jstests/core/geo_near_random1.js
+++ b/jstests/core/geo_near_random1.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// this tests all points
load("jstests/libs/geo_near_random.js");
diff --git a/jstests/core/geo_near_random2.js b/jstests/core/geo_near_random2.js
index e742c4a639e..0cbf374446d 100644
--- a/jstests/core/geo_near_random2.js
+++ b/jstests/core/geo_near_random2.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// this tests 1% of all points
load("jstests/libs/geo_near_random.js");
diff --git a/jstests/core/geo_or.js b/jstests/core/geo_or.js
index 4d953dbf9de..1324d581be8 100644
--- a/jstests/core/geo_or.js
+++ b/jstests/core/geo_or.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// multiple geo clauses with $or
t = db.geoor;
diff --git a/jstests/core/geo_queryoptimizer.js b/jstests/core/geo_queryoptimizer.js
index e8aad815761..af55507ff86 100644
--- a/jstests/core/geo_queryoptimizer.js
+++ b/jstests/core/geo_queryoptimizer.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
t = db.geo_qo1;
t.drop();
diff --git a/jstests/core/geo_regex0.js b/jstests/core/geo_regex0.js
index 4584192e15f..1add7f4e0c3 100644
--- a/jstests/core/geo_regex0.js
+++ b/jstests/core/geo_regex0.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// From SERVER-2247
// Tests to make sure regex works with geo indices
diff --git a/jstests/core/geo_s2dedupnear.js b/jstests/core/geo_s2dedupnear.js
index e1f624f7553..21378893720 100644
--- a/jstests/core/geo_s2dedupnear.js
+++ b/jstests/core/geo_s2dedupnear.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// Make sure that we don't return several of the same result due to faulty
// assumptions about the btree cursor. That is, don't return duplicate results.
t = db.geo_s2dedupnear;
diff --git a/jstests/core/geo_s2disjoint_holes.js b/jstests/core/geo_s2disjoint_holes.js
index 0b088434b36..f7731b416e4 100644
--- a/jstests/core/geo_s2disjoint_holes.js
+++ b/jstests/core/geo_s2disjoint_holes.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
//
// We should prohibit polygons with holes not bounded by their exterior shells.
//
diff --git a/jstests/core/geo_s2index.js b/jstests/core/geo_s2index.js
index 65bf5953661..99c3852aae9 100644
--- a/jstests/core/geo_s2index.js
+++ b/jstests/core/geo_s2index.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
t = db.geo_s2index;
t.drop();
diff --git a/jstests/core/geo_s2indexversion1.js b/jstests/core/geo_s2indexversion1.js
index d9797a67505..4fa58bb589f 100644
--- a/jstests/core/geo_s2indexversion1.js
+++ b/jstests/core/geo_s2indexversion1.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Tests 2dsphere index option "2dsphereIndexVersion". Verifies that GeoJSON objects that are new
// in version 2 are not allowed in version 1.
diff --git a/jstests/core/geo_s2meridian.js b/jstests/core/geo_s2meridian.js
index e404241e118..583b426845c 100644
--- a/jstests/core/geo_s2meridian.js
+++ b/jstests/core/geo_s2meridian.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
t = db.geo_s2meridian;
t.drop();
t.ensureIndex({geo: "2dsphere"});
diff --git a/jstests/core/geo_s2near.js b/jstests/core/geo_s2near.js
index 75572483144..f8bacf350b4 100644
--- a/jstests/core/geo_s2near.js
+++ b/jstests/core/geo_s2near.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// Test 2dsphere near search, called via find and geoNear.
t = db.geo_s2near;
t.drop();
diff --git a/jstests/core/geo_s2nearComplex.js b/jstests/core/geo_s2nearComplex.js
index b8c34c16310..bf9c76ffde4 100644
--- a/jstests/core/geo_s2nearComplex.js
+++ b/jstests/core/geo_s2nearComplex.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
var t = db.get_s2nearcomplex;
t.drop();
t.ensureIndex({geo: "2dsphere"});
diff --git a/jstests/core/geo_s2near_equator_opposite.js b/jstests/core/geo_s2near_equator_opposite.js
index 378a8d89854..754c27e523d 100644
--- a/jstests/core/geo_s2near_equator_opposite.js
+++ b/jstests/core/geo_s2near_equator_opposite.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// Tests geo near with 2 points diametrically opposite to each other
// on the equator
// First reported in SERVER-11830 as a regression in 2.5
diff --git a/jstests/core/geo_s2nearcorrect.js b/jstests/core/geo_s2nearcorrect.js
index b80bfbf5971..54552a4bee5 100644
--- a/jstests/core/geo_s2nearcorrect.js
+++ b/jstests/core/geo_s2nearcorrect.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// SERVER-9484
// A geometry may have several covers, one of which is in a search ring and the other of which is
// not. If we see the cover that's not in the search ring, we can't mark the object as 'seen' for
diff --git a/jstests/core/geo_s2nongeoarray.js b/jstests/core/geo_s2nongeoarray.js
index ff027ee1a4f..4b210f8f779 100644
--- a/jstests/core/geo_s2nongeoarray.js
+++ b/jstests/core/geo_s2nongeoarray.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// Explode arrays when indexing non-geo fields in 2dsphere, and make sure that
// we find them with queries.
t = db.geo_s2nongeoarray;
diff --git a/jstests/core/geo_s2nonstring.js b/jstests/core/geo_s2nonstring.js
index e868ade1009..960f0c727a8 100644
--- a/jstests/core/geo_s2nonstring.js
+++ b/jstests/core/geo_s2nonstring.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// Added to make sure that S2 indexing's string AND non-string keys work.
t = db.geo_s2nonstring;
t.drop();
diff --git a/jstests/core/geo_s2nopoints.js b/jstests/core/geo_s2nopoints.js
index 1a92b546764..0d2afdb1672 100644
--- a/jstests/core/geo_s2nopoints.js
+++ b/jstests/core/geo_s2nopoints.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// See SERVER-7794.
t = db.geo_s2nopoints;
t.drop();
diff --git a/jstests/core/geo_small_large.js b/jstests/core/geo_small_large.js
index 4bdd90da371..549f00369a2 100644
--- a/jstests/core/geo_small_large.js
+++ b/jstests/core/geo_small_large.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// SERVER-2386, general geo-indexing using very large and very small bounds
load("jstests/libs/geo_near_random.js");
diff --git a/jstests/core/geo_sort1.js b/jstests/core/geo_sort1.js
index 88a7971841a..b7a229bb8ae 100644
--- a/jstests/core/geo_sort1.js
+++ b/jstests/core/geo_sort1.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
t = db.geo_sort1;
t.drop();
diff --git a/jstests/core/geo_uniqueDocs2.js b/jstests/core/geo_uniqueDocs2.js
index 8965a475c93..6f5ceed3478 100644
--- a/jstests/core/geo_uniqueDocs2.js
+++ b/jstests/core/geo_uniqueDocs2.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// Additional checks for geo uniqueDocs and includeLocs SERVER-3139.
// SERVER-12120 uniqueDocs is deprecated.
// Server always returns results with implied uniqueDocs=true
diff --git a/jstests/core/geo_update.js b/jstests/core/geo_update.js
index e6ee16eee59..ebe754680e9 100644
--- a/jstests/core/geo_update.js
+++ b/jstests/core/geo_update.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Tests geo queries w/ update & upsert
// from SERVER-3428
diff --git a/jstests/core/geo_update_dedup.js b/jstests/core/geo_update_dedup.js
index da84e9879a2..a630954e8ca 100644
--- a/jstests/core/geo_update_dedup.js
+++ b/jstests/core/geo_update_dedup.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// Test that updates with geo queries which match
// the same document multiple times only apply
// the update once
diff --git a/jstests/core/geoa.js b/jstests/core/geoa.js
index 1c1272a6451..cd1eeaf5aaa 100644
--- a/jstests/core/geoa.js
+++ b/jstests/core/geoa.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
t = db.geoa;
t.drop();
diff --git a/jstests/core/geoc.js b/jstests/core/geoc.js
index 93f3f5c374a..26e762e4978 100644
--- a/jstests/core/geoc.js
+++ b/jstests/core/geoc.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
t = db.geoc;
t.drop();
diff --git a/jstests/core/geof.js b/jstests/core/geof.js
index ed10c6496c6..4eae803a856 100644
--- a/jstests/core/geof.js
+++ b/jstests/core/geof.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
t = db.geof;
t.drop();
diff --git a/jstests/core/getmore_cmd_maxtimems.js b/jstests/core/getmore_cmd_maxtimems.js
index 9ea4a872043..a0c82667756 100644
--- a/jstests/core/getmore_cmd_maxtimems.js
+++ b/jstests/core/getmore_cmd_maxtimems.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Test attaching maxTimeMS to a getMore command.
(function() {
'use strict';
diff --git a/jstests/core/getmore_invalidation.js b/jstests/core/getmore_invalidation.js
index e6d38b980df..5c5d06deb1c 100644
--- a/jstests/core/getmore_invalidation.js
+++ b/jstests/core/getmore_invalidation.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Tests for invalidation during a getmore. This behavior is storage-engine dependent.
// See SERVER-16675.
(function() {
diff --git a/jstests/core/group1.js b/jstests/core/group1.js
index 579c706ee3d..5e4fcdea245 100644
--- a/jstests/core/group1.js
+++ b/jstests/core/group1.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of unsupported group operator on sharded
-// collection.
-// @tags: [assumes_unsharded_collection]
-
t = db.group1;
t.drop();
diff --git a/jstests/core/group2.js b/jstests/core/group2.js
index 5dc0ddce93d..1577932beca 100644
--- a/jstests/core/group2.js
+++ b/jstests/core/group2.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of unsupported group operator on sharded
-// collection.
-// @tags: [assumes_unsharded_collection]
-
t = db.group2;
t.drop();
diff --git a/jstests/core/group3.js b/jstests/core/group3.js
index 3840e8bcbcc..134953b6649 100644
--- a/jstests/core/group3.js
+++ b/jstests/core/group3.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of unsupported group operator on sharded
-// collection.
-// @tags: [assumes_unsharded_collection]
-
t = db.group3;
t.drop();
diff --git a/jstests/core/group4.js b/jstests/core/group4.js
index e2d9e9546fc..2465274c027 100644
--- a/jstests/core/group4.js
+++ b/jstests/core/group4.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of unsupported group operator on sharded
-// collection.
-// @tags: [assumes_unsharded_collection]
t = db.group4;
t.drop();
diff --git a/jstests/core/group5.js b/jstests/core/group5.js
index 2f57e110d50..aa6283f73ff 100644
--- a/jstests/core/group5.js
+++ b/jstests/core/group5.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of unsupported group operator on sharded
-// collection.
-// @tags: [assumes_unsharded_collection]
t = db.group5;
t.drop();
diff --git a/jstests/core/group6.js b/jstests/core/group6.js
index 77ac0355d3e..fff2fcaafd7 100644
--- a/jstests/core/group6.js
+++ b/jstests/core/group6.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of unsupported group operator on sharded
-// collection.
-// @tags: [assumes_unsharded_collection]
-
t = db.jstests_group6;
t.drop();
diff --git a/jstests/core/group8.js b/jstests/core/group8.js
index 029d430103f..85c8248b992 100644
--- a/jstests/core/group8.js
+++ b/jstests/core/group8.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of unsupported group operator on sharded
-// collection.
-// @tags: [assumes_unsharded_collection]
-
// Test correctness of the "keys" and and "count" fields in the group command output.
var coll = db.group8;
var result;
diff --git a/jstests/core/group9.js b/jstests/core/group9.js
index 17cd3ae94db..a7d9a0d128e 100644
--- a/jstests/core/group9.js
+++ b/jstests/core/group9.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of unsupported group operator on sharded
-// collection.
-// @tags: [assumes_unsharded_collection]
-
(function() {
'use strict';
var t = db.group_owned;
diff --git a/jstests/core/hashindex1.js b/jstests/core/hashindex1.js
index 2e05f9fe3da..93986ecfd5e 100644
--- a/jstests/core/hashindex1.js
+++ b/jstests/core/hashindex1.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
var t = db.hashindex1;
t.drop();
diff --git a/jstests/core/in5.js b/jstests/core/in5.js
index 69b7bad75dd..772427365b7 100644
--- a/jstests/core/in5.js
+++ b/jstests/core/in5.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
t = db.in5;
diff --git a/jstests/core/inc-SERVER-7446.js b/jstests/core/inc-SERVER-7446.js
index b1d5aa158d0..2503df21f87 100644
--- a/jstests/core/inc-SERVER-7446.js
+++ b/jstests/core/inc-SERVER-7446.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
var c = db.incSERVER7446;
// A 32 bit overflow spills to 64 bits
diff --git a/jstests/core/inc3.js b/jstests/core/inc3.js
index e24165876c6..b69a77c64cd 100644
--- a/jstests/core/inc3.js
+++ b/jstests/core/inc3.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.inc3;
diff --git a/jstests/core/index3.js b/jstests/core/index3.js
index 6ae7c4b82dd..e908f1fe2c9 100644
--- a/jstests/core/index3.js
+++ b/jstests/core/index3.js
@@ -1,6 +1,4 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
+
t = db.index3;
t.drop();
diff --git a/jstests/core/index4.js b/jstests/core/index4.js
index b9411a8fe37..1c96ded434a 100644
--- a/jstests/core/index4.js
+++ b/jstests/core/index4.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
// index4.js
t = db.index4;
diff --git a/jstests/core/index8.js b/jstests/core/index8.js
index b74cbb5c708..6773f2d29f5 100644
--- a/jstests/core/index8.js
+++ b/jstests/core/index8.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of not being able to create unique index
-// using hashed shard key pattern.
-// @tags: [cannot_create_unique_index_when_using_hashed_shard_key]
-
// Test key uniqueness
t = db.jstests_index8;
diff --git a/jstests/core/index9.js b/jstests/core/index9.js
index 028578e5460..5f31dc978aa 100644
--- a/jstests/core/index9.js
+++ b/jstests/core/index9.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
t = db.jstests_index9;
t.drop();
diff --git a/jstests/core/index_arr1.js b/jstests/core/index_arr1.js
index cc6f1683bd1..ba821bd3730 100644
--- a/jstests/core/index_arr1.js
+++ b/jstests/core/index_arr1.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
t = db.index_arr1;
t.drop();
diff --git a/jstests/core/index_big1.js b/jstests/core/index_big1.js
index 304656dda9a..8f600fa37bc 100644
--- a/jstests/core/index_big1.js
+++ b/jstests/core/index_big1.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
// check where "key to big" happens
t = db.index_big1;
diff --git a/jstests/core/index_bigkeys.js b/jstests/core/index_bigkeys.js
index 6d98859132e..564ddde2a5e 100644
--- a/jstests/core/index_bigkeys.js
+++ b/jstests/core/index_bigkeys.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
t = db.bigkeysidxtest;
diff --git a/jstests/core/index_decimal.js b/jstests/core/index_decimal.js
index 312ab106674..d9642f090d9 100644
--- a/jstests/core/index_decimal.js
+++ b/jstests/core/index_decimal.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because queries on a sharded collection are not
-// able to be covered when they aren't on the shard key since the document needs to be fetched in
-// order to apply the SHARDING_FILTER stage.
-// @tags: [assumes_unsharded_collection]
-
// Test indexing of decimal numbers
(function() {
'use strict';
diff --git a/jstests/core/index_dropdups_ignore.js b/jstests/core/index_dropdups_ignore.js
index af75f57a601..3622d800b01 100644
--- a/jstests/core/index_dropdups_ignore.js
+++ b/jstests/core/index_dropdups_ignore.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of not being able to create unique index
-// using hashed shard key pattern.
-// @tags: [cannot_create_unique_index_when_using_hashed_shard_key]
-
// SERVER-14710 dropDups is ignored and stripped from the spec when building an index.
var t = db.index_dropdups_ignore;
diff --git a/jstests/core/index_filter_commands.js b/jstests/core/index_filter_commands.js
index d0973aacd69..8684be3b2b9 100644
--- a/jstests/core/index_filter_commands.js
+++ b/jstests/core/index_filter_commands.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
/**
* Index Filter commands
*
diff --git a/jstests/core/index_id_options.js b/jstests/core/index_id_options.js
index 9bbf3a2d311..a387c409b6d 100644
--- a/jstests/core/index_id_options.js
+++ b/jstests/core/index_id_options.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Test creation of the _id index with various options:
// - _id indexes must have key pattern {_id: 1}.
// - The name of an _id index gets corrected to "_id_".
diff --git a/jstests/core/index_many.js b/jstests/core/index_many.js
index 3fae520fe81..f2daa8c9fcf 100644
--- a/jstests/core/index_many.js
+++ b/jstests/core/index_many.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because renameCollection command not supported
-// on sharded collections.
-// @tags: [assumes_unsharded_collection]
-
/* test using lots of indexes on one collection */
t = db.many;
diff --git a/jstests/core/index_many2.js b/jstests/core/index_many2.js
index c7f993e35e5..87e99898b1f 100644
--- a/jstests/core/index_many2.js
+++ b/jstests/core/index_many2.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
t = db.index_many2;
t.drop();
diff --git a/jstests/core/index_multiple_compatibility.js b/jstests/core/index_multiple_compatibility.js
index 15f47d773e0..6544c4c7cbf 100644
--- a/jstests/core/index_multiple_compatibility.js
+++ b/jstests/core/index_multiple_compatibility.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of not being able to create unique index
-// using hashed shard key pattern.
-// @tags: [cannot_create_unique_index_when_using_hashed_shard_key]
-
// Test that multiple indexes behave correctly together.
(function() {
'use strict';
diff --git a/jstests/core/index_partial_create_drop.js b/jstests/core/index_partial_create_drop.js
index 5875093c706..1c8552804b3 100644
--- a/jstests/core/index_partial_create_drop.js
+++ b/jstests/core/index_partial_create_drop.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
// Test partial index creation and drops.
(function() {
diff --git a/jstests/core/index_partial_read_ops.js b/jstests/core/index_partial_read_ops.js
index bef51700b27..42f77486c17 100644
--- a/jstests/core/index_partial_read_ops.js
+++ b/jstests/core/index_partial_read_ops.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because the explain output from a mongod when run
-// against a sharded collection is wrapped in a "shards" object with keys for each shard.
-// @tags: [assumes_unsharded_collection]
-
// Read ops tests for partial indexes.
// Include helpers for analyzing explain output.
diff --git a/jstests/core/index_sparse1.js b/jstests/core/index_sparse1.js
index 49decd3783c..d71c3c1dbfe 100644
--- a/jstests/core/index_sparse1.js
+++ b/jstests/core/index_sparse1.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
t = db.index_sparse1;
t.drop();
diff --git a/jstests/core/index_sparse2.js b/jstests/core/index_sparse2.js
index 0cb72567e57..702bb8cd5f8 100644
--- a/jstests/core/index_sparse2.js
+++ b/jstests/core/index_sparse2.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
t = db.index_sparse2;
t.drop();
diff --git a/jstests/core/index_stats.js b/jstests/core/index_stats.js
index b8187e76de2..b912543bcb9 100644
--- a/jstests/core/index_stats.js
+++ b/jstests/core/index_stats.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
(function() {
"use strict";
diff --git a/jstests/core/index_type_change.js b/jstests/core/index_type_change.js
index 37e1d4c06e3..0c95828ae57 100644
--- a/jstests/core/index_type_change.js
+++ b/jstests/core/index_type_change.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
/**
* Tests that replacing a document with an equivalent document with different types for the fields
* will update the index entries associated with that document.
diff --git a/jstests/core/indexa.js b/jstests/core/indexa.js
index 33ffaa4bf78..be86c9acf54 100644
--- a/jstests/core/indexa.js
+++ b/jstests/core/indexa.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
// unique index constraint test for updates
// case where object doesn't grow tested here
diff --git a/jstests/core/indexapi.js b/jstests/core/indexapi.js
index 3153519501a..2df9709171d 100644
--- a/jstests/core/indexapi.js
+++ b/jstests/core/indexapi.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of not being able to create unique index
-// using hashed shard key pattern.
-// @tags: [cannot_create_unique_index_when_using_hashed_shard_key]
t = db.indexapi;
t.drop();
diff --git a/jstests/core/indexb.js b/jstests/core/indexb.js
index c852ff083f4..1262c621ba9 100644
--- a/jstests/core/indexb.js
+++ b/jstests/core/indexb.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of not being able to create unique index
-// using hashed shard key pattern.
-// @tags: [cannot_create_unique_index_when_using_hashed_shard_key]
-
// unique index test for a case where the object grows
// and must move
diff --git a/jstests/core/indexes_multiple_commands.js b/jstests/core/indexes_multiple_commands.js
index fe27c3a93a2..5396f5e6b2e 100644
--- a/jstests/core/indexes_multiple_commands.js
+++ b/jstests/core/indexes_multiple_commands.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Test that commands behave correctly under the presence of multiple indexes with the same key
// pattern.
(function() {
diff --git a/jstests/core/insert2.js b/jstests/core/insert2.js
index 5da0fc5b7f5..f01fd153d0c 100644
--- a/jstests/core/insert2.js
+++ b/jstests/core/insert2.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Create a new connection object so it won't affect the global connection when we modify
// it's settings.
var conn = new Mongo(db.getMongo().host);
diff --git a/jstests/core/insert_id_undefined.js b/jstests/core/insert_id_undefined.js
index 5dc2c9a6862..874d6c0228c 100644
--- a/jstests/core/insert_id_undefined.js
+++ b/jstests/core/insert_id_undefined.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// ensure a document with _id undefined cannot be saved
t = db.insert_id_undefined;
t.drop();
diff --git a/jstests/core/js3.js b/jstests/core/js3.js
index 7a612a1bdee..4d46c25bbf7 100644
--- a/jstests/core/js3.js
+++ b/jstests/core/js3.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// from db.eval.
-// @tags: [assumes_unsharded_collection]
t = db.jstests_js3;
diff --git a/jstests/core/js9.js b/jstests/core/js9.js
index 808ae9a0998..515fa883aea 100644
--- a/jstests/core/js9.js
+++ b/jstests/core/js9.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// from db.eval.
-// @tags: [assumes_unsharded_collection]
-
c = db.jstests_js9;
c.drop();
diff --git a/jstests/core/list_collections1.js b/jstests/core/list_collections1.js
index 2aeb9ec9fbd..c8c3f92fbc9 100644
--- a/jstests/core/list_collections1.js
+++ b/jstests/core/list_collections1.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Basic functional tests for the listCollections command.
//
// Note that storage engines are allowed to advertise internal collections to the user (in
diff --git a/jstests/core/list_indexes.js b/jstests/core/list_indexes.js
index 90abc0f4c62..de0f4473980 100644
--- a/jstests/core/list_indexes.js
+++ b/jstests/core/list_indexes.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
// Basic functional tests for the listIndexes command.
(function() {
diff --git a/jstests/core/list_indexes_invalid.js b/jstests/core/list_indexes_invalid.js
index 43d64a594c2..0e9c5ffa88c 100644
--- a/jstests/core/list_indexes_invalid.js
+++ b/jstests/core/list_indexes_invalid.js
@@ -1,36 +1,32 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
-
-// Test for invalid values of "cursor" and "cursor.batchSize".
-
-var coll = db.list_indexes_invalid;
-coll.drop();
-
-assert.commandWorked(coll.getDB().createCollection(coll.getName()));
-assert.commandWorked(coll.ensureIndex({a: 1}, {unique: true}));
-
-assert.throws(function() {
- getListIndexesCursor(coll, {cursor: 0});
-});
-assert.throws(function() {
- getListIndexesCursor(coll, {cursor: 'x'});
-});
-assert.throws(function() {
- getListIndexesCursor(coll, {cursor: []});
-});
-assert.throws(function() {
- getListIndexesCursor(coll, {cursor: {foo: 1}});
-});
-assert.throws(function() {
- getListIndexesCursor(coll, {cursor: {batchSize: -1}});
-});
-assert.throws(function() {
- getListIndexesCursor(coll, {cursor: {batchSize: 'x'}});
-});
-assert.throws(function() {
- getListIndexesCursor(coll, {cursor: {batchSize: {}}});
-});
-assert.throws(function() {
- getListIndexesCursor(coll, {cursor: {batchSize: 2, foo: 1}});
-});
+// Test for invalid values of "cursor" and "cursor.batchSize".
+
+var coll = db.list_indexes_invalid;
+coll.drop();
+
+assert.commandWorked(coll.getDB().createCollection(coll.getName()));
+assert.commandWorked(coll.ensureIndex({a: 1}, {unique: true}));
+
+assert.throws(function() {
+ getListIndexesCursor(coll, {cursor: 0});
+});
+assert.throws(function() {
+ getListIndexesCursor(coll, {cursor: 'x'});
+});
+assert.throws(function() {
+ getListIndexesCursor(coll, {cursor: []});
+});
+assert.throws(function() {
+ getListIndexesCursor(coll, {cursor: {foo: 1}});
+});
+assert.throws(function() {
+ getListIndexesCursor(coll, {cursor: {batchSize: -1}});
+});
+assert.throws(function() {
+ getListIndexesCursor(coll, {cursor: {batchSize: 'x'}});
+});
+assert.throws(function() {
+ getListIndexesCursor(coll, {cursor: {batchSize: {}}});
+});
+assert.throws(function() {
+ getListIndexesCursor(coll, {cursor: {batchSize: 2, foo: 1}});
+});
diff --git a/jstests/core/list_indexes_invalidation.js b/jstests/core/list_indexes_invalidation.js
index c9500ebd5e0..b8cbe5eb134 100644
--- a/jstests/core/list_indexes_invalidation.js
+++ b/jstests/core/list_indexes_invalidation.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because renameCollection command not supported
-// on sharded collections.
-// @tags: [assumes_unsharded_collection]
-
// SERVER-24963/SERVER-27930 Missing invalidation for system.indexes writes
(function() {
'use strict';
diff --git a/jstests/core/mr2.js b/jstests/core/mr2.js
index be17658ffd7..744fb916088 100644
--- a/jstests/core/mr2.js
+++ b/jstests/core/mr2.js
@@ -1,6 +1,4 @@
-// Cannot implicitly shard accessed collections because the "jsMode" option to the "mapReduce"
-// command cannot be used on a sharded collection.
-// @tags: [assumes_unsharded_collection]
+
t = db.mr2;
t.drop();
diff --git a/jstests/core/mr_bigobject_replace.js b/jstests/core/mr_bigobject_replace.js
index da7c08c0e3a..c30b6e5de48 100644
--- a/jstests/core/mr_bigobject_replace.js
+++ b/jstests/core/mr_bigobject_replace.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: Cannot output to a
-// non-sharded collection because sharded collection exists already.
-// @tags: [assumes_unsharded_collection]
-
/**
* Test that the server returns an error response for map-reduce operations that attempt to insert a
* document larger than 16MB as a result of the reduce() or finalize() functions and using the
diff --git a/jstests/core/mr_errorhandling.js b/jstests/core/mr_errorhandling.js
index 8da061459d2..d3fcdc3dcac 100644
--- a/jstests/core/mr_errorhandling.js
+++ b/jstests/core/mr_errorhandling.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of collection existing when none
-// expected.
-// @tags: [assumes_no_implicit_collection_creation_after_drop]
t = db.mr_errorhandling;
t.drop();
diff --git a/jstests/core/mr_killop.js b/jstests/core/mr_killop.js
index dc1a646d52d..78e98f0bcaa 100644
--- a/jstests/core/mr_killop.js
+++ b/jstests/core/mr_killop.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because the "query" field in the currentOp()
-// output is reported as {"mapreduce.shardedfinish": { mapreduce: "jstests_mr_killop", ... }, ... }
-// when the "finalize" option to the "mapReduce" command is used on a sharded collection.
-// @tags: [assumes_unsharded_collection]
-
// Test killop applied to m/r operations and child ops of m/r operations.
t = db.jstests_mr_killop;
diff --git a/jstests/core/mr_merge.js b/jstests/core/mr_merge.js
index e81e8f57b0d..92490cdd6fd 100644
--- a/jstests/core/mr_merge.js
+++ b/jstests/core/mr_merge.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: Cannot output to a
-// non-sharded collection because sharded collection exists already.
-// @tags: [assumes_unsharded_collection]
t = db.mr_merge;
t.drop();
diff --git a/jstests/core/mr_merge2.js b/jstests/core/mr_merge2.js
index db4e83377ab..e324c124f29 100644
--- a/jstests/core/mr_merge2.js
+++ b/jstests/core/mr_merge2.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: Cannot output to a
-// non-sharded collection because sharded collection exists already.
-// @tags: [assumes_unsharded_collection]
t = db.mr_merge2;
t.drop();
diff --git a/jstests/core/mr_outreduce.js b/jstests/core/mr_outreduce.js
index 01fcb1704ba..d23b0714a51 100644
--- a/jstests/core/mr_outreduce.js
+++ b/jstests/core/mr_outreduce.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: Cannot output to a
-// non-sharded collection because sharded collection exists already.
-// @tags: [assumes_unsharded_collection]
t = db.mr_outreduce;
t.drop();
diff --git a/jstests/core/mr_outreduce2.js b/jstests/core/mr_outreduce2.js
index cb9f3379d07..a08b6b51527 100644
--- a/jstests/core/mr_outreduce2.js
+++ b/jstests/core/mr_outreduce2.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: Cannot output to a
-// non-sharded collection because sharded collection exists already.
-// @tags: [assumes_unsharded_collection]
normal = "mr_outreduce2";
out = normal + "_out";
diff --git a/jstests/core/mr_sort.js b/jstests/core/mr_sort.js
index fe1a5a48beb..b90ad3f6bf5 100644
--- a/jstests/core/mr_sort.js
+++ b/jstests/core/mr_sort.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because the "limit" option to the "mapReduce"
-// command cannot be used on a sharded collection.
-// @tags: [assumes_unsharded_collection]
t = db.mr_sort;
t.drop();
diff --git a/jstests/core/multikey_geonear.js b/jstests/core/multikey_geonear.js
index 266690d0f3a..6d796cb62ff 100644
--- a/jstests/core/multikey_geonear.js
+++ b/jstests/core/multikey_geonear.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of use of $near query instead of geoNear
-// command.
-// @tags: [assumes_unsharded_collection]
-
// Test that we correct return results for compound 2d and 2dsphere indices in
// both the multikey and non-multikey cases.
diff --git a/jstests/core/or4.js b/jstests/core/or4.js
index 42e770e4292..6053295a7d1 100644
--- a/jstests/core/or4.js
+++ b/jstests/core/or4.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of unsupported group operator on sharded
-// collection.
-// @tags: [assumes_unsharded_collection]
-
t = db.jstests_or4;
t.drop();
diff --git a/jstests/core/projection_dotted_paths.js b/jstests/core/projection_dotted_paths.js
index f72a6d30bd6..bdddbeac749 100644
--- a/jstests/core/projection_dotted_paths.js
+++ b/jstests/core/projection_dotted_paths.js
@@ -1,7 +1,3 @@
-// Failing due to queries on a sharded collection not able to be covered when they aren't on the
-// shard key since the document needs to be fetched in order to apply the SHARDING_FILTER stage.
-// @tags: [assumes_unsharded_collection]
-
/**
* Test projections with dotted field paths. Also test that such projections result in covered plans
* when appropriate.
diff --git a/jstests/core/pull.js b/jstests/core/pull.js
index 612c65f9e65..d2d03e85144 100644
--- a/jstests/core/pull.js
+++ b/jstests/core/pull.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
t = db.jstests_pull;
t.drop();
diff --git a/jstests/core/pull2.js b/jstests/core/pull2.js
index bc9b1acba4b..861d5164c03 100644
--- a/jstests/core/pull2.js
+++ b/jstests/core/pull2.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.pull2;
t.drop();
diff --git a/jstests/core/pull_or.js b/jstests/core/pull_or.js
index 9ef1e091d29..a91d88c2c18 100644
--- a/jstests/core/pull_or.js
+++ b/jstests/core/pull_or.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.pull_or;
t.drop();
diff --git a/jstests/core/pull_remove1.js b/jstests/core/pull_remove1.js
index ab9368bab3b..926dcbf9575 100644
--- a/jstests/core/pull_remove1.js
+++ b/jstests/core/pull_remove1.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.pull_remove1;
t.drop();
diff --git a/jstests/core/pullall.js b/jstests/core/pullall.js
index 2cd0872b079..2925a45623f 100644
--- a/jstests/core/pullall.js
+++ b/jstests/core/pullall.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
t = db.jstests_pullall;
t.drop();
diff --git a/jstests/core/pullall2.js b/jstests/core/pullall2.js
index 10e8c89caa1..92d835c0dab 100644
--- a/jstests/core/pullall2.js
+++ b/jstests/core/pullall2.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.pullall2;
t.drop();
diff --git a/jstests/core/pushall.js b/jstests/core/pushall.js
index bf777d8a08a..e9d388e6f6f 100644
--- a/jstests/core/pushall.js
+++ b/jstests/core/pushall.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
t = db.jstests_pushall;
t.drop();
diff --git a/jstests/core/remove8.js b/jstests/core/remove8.js
index 2935c9647bc..563e4708cf9 100644
--- a/jstests/core/remove8.js
+++ b/jstests/core/remove8.js
@@ -1,6 +1,3 @@
-// Cannot implicitly shard accessed collections because unsupported use of sharded collection
-// from db.eval.
-// @tags: [assumes_unsharded_collection]
t = db.remove8;
t.drop();
diff --git a/jstests/core/remove_justone.js b/jstests/core/remove_justone.js
index a8b6ba318ee..04813149dfd 100644
--- a/jstests/core/remove_justone.js
+++ b/jstests/core/remove_justone.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.remove_justone;
t.drop();
diff --git a/jstests/core/return_key.js b/jstests/core/return_key.js
index b2442b43e6f..3692521f58c 100644
--- a/jstests/core/return_key.js
+++ b/jstests/core/return_key.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because queries on a sharded collection are not
-// able to be covered when they aren't on the shard key since the document needs to be fetched in
-// order to apply the SHARDING_FILTER stage.
-// @tags: [assumes_unsharded_collection]
-
/**
* Tests for returnKey.
*/
diff --git a/jstests/core/server1470.js b/jstests/core/server1470.js
index 05482017c2e..42587961665 100644
--- a/jstests/core/server1470.js
+++ b/jstests/core/server1470.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.server1470;
t.drop();
diff --git a/jstests/core/set3.js b/jstests/core/set3.js
index 4af579fa0b9..8f7d78d894f 100644
--- a/jstests/core/set3.js
+++ b/jstests/core/set3.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.set3;
t.drop();
diff --git a/jstests/core/set4.js b/jstests/core/set4.js
index 99c0913b977..989cf82b223 100644
--- a/jstests/core/set4.js
+++ b/jstests/core/set4.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.set4;
t.drop();
diff --git a/jstests/core/set5.js b/jstests/core/set5.js
index a848899f4af..dfa28b1e3e8 100644
--- a/jstests/core/set5.js
+++ b/jstests/core/set5.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.set5;
t.drop();
diff --git a/jstests/core/set6.js b/jstests/core/set6.js
index 2f82eb40a68..bf0ece0dbf8 100644
--- a/jstests/core/set6.js
+++ b/jstests/core/set6.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.set6;
t.drop();
diff --git a/jstests/core/set7.js b/jstests/core/set7.js
index 9e1d9c29bbc..8aba33aee94 100644
--- a/jstests/core/set7.js
+++ b/jstests/core/set7.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// test $set with array indicies
t = db.jstests_set7;
diff --git a/jstests/core/set_type_change.js b/jstests/core/set_type_change.js
index ede59f7bcde..1f24a7c953a 100644
--- a/jstests/core/set_type_change.js
+++ b/jstests/core/set_type_change.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
/**
* Tests that using the $set update modifier to change only the type of a field will actually update
* the document, including any relevant indices.
diff --git a/jstests/core/shell_writeconcern.js b/jstests/core/shell_writeconcern.js
index 9f3fc271ce2..f3f190061cf 100644
--- a/jstests/core/shell_writeconcern.js
+++ b/jstests/core/shell_writeconcern.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
"use strict";
// check that shell writeconcern work correctly
// 1.) tests that it can be set on each level and is inherited
diff --git a/jstests/core/sortg.js b/jstests/core/sortg.js
index 7cdf308444d..726fe9184a6 100644
--- a/jstests/core/sortg.js
+++ b/jstests/core/sortg.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of extra shard key index in sharded
-// collection.
-// @tags: [assumes_no_implicit_index_creation]
-
// Test that a memory exception is triggered for in memory sorts, but not for indexed sorts.
t = db.jstests_sortg;
diff --git a/jstests/core/splitvector.js b/jstests/core/splitvector.js
index 83e653e992c..9ba62e2df83 100644
--- a/jstests/core/splitvector.js
+++ b/jstests/core/splitvector.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because the "splitVector" command cannot be run
-// on a sharded collection
-// @tags: [assumes_unsharded_collection]
-
// -------------------------
// SPLITVECTOR TEST UTILS
// -------------------------
diff --git a/jstests/core/uniqueness.js b/jstests/core/uniqueness.js
index e67d19dcbe6..8b919b9a6a9 100644
--- a/jstests/core/uniqueness.js
+++ b/jstests/core/uniqueness.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of not being able to create unique index
-// using hashed shard key pattern.
-// @tags: [cannot_create_unique_index_when_using_hashed_shard_key]
-
var res;
t = db.jstests_uniqueness;
diff --git a/jstests/core/unset2.js b/jstests/core/unset2.js
index e120ae2b674..ec2772af507 100644
--- a/jstests/core/unset2.js
+++ b/jstests/core/unset2.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
var res;
t = db.unset2;
diff --git a/jstests/core/update2.js b/jstests/core/update2.js
index 558e3c7f558..15d84c81b41 100644
--- a/jstests/core/update2.js
+++ b/jstests/core/update2.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
f = db.ed_db_update2;
f.drop();
diff --git a/jstests/core/update3.js b/jstests/core/update3.js
index 4974f8c022b..79562fe72d0 100644
--- a/jstests/core/update3.js
+++ b/jstests/core/update3.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Update with mods corner cases.
f = db.jstests_update3;
diff --git a/jstests/core/update5.js b/jstests/core/update5.js
index e0fee23c7fe..3ee44d2fba0 100644
--- a/jstests/core/update5.js
+++ b/jstests/core/update5.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.update5;
diff --git a/jstests/core/update6.js b/jstests/core/update6.js
index efbb7c365e8..76b676260f6 100644
--- a/jstests/core/update6.js
+++ b/jstests/core/update6.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.update6;
t.drop();
diff --git a/jstests/core/update7.js b/jstests/core/update7.js
index 3908c0786d3..9f92c3382ef 100644
--- a/jstests/core/update7.js
+++ b/jstests/core/update7.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.update7;
t.drop();
diff --git a/jstests/core/update_addToSet.js b/jstests/core/update_addToSet.js
index f7252b29586..05437148b2f 100644
--- a/jstests/core/update_addToSet.js
+++ b/jstests/core/update_addToSet.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.update_addToSet1;
t.drop();
diff --git a/jstests/core/update_arraymatch1.js b/jstests/core/update_arraymatch1.js
index 10b7e37e451..b8d78c3daee 100644
--- a/jstests/core/update_arraymatch1.js
+++ b/jstests/core/update_arraymatch1.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.update_arraymatch1;
t.drop();
diff --git a/jstests/core/update_arraymatch4.js b/jstests/core/update_arraymatch4.js
index bda7de512b8..fabe07f7337 100644
--- a/jstests/core/update_arraymatch4.js
+++ b/jstests/core/update_arraymatch4.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.update_arraymatch4;
t.drop();
diff --git a/jstests/core/update_arraymatch6.js b/jstests/core/update_arraymatch6.js
index a32bbf3c7d7..fe4b09de8a0 100644
--- a/jstests/core/update_arraymatch6.js
+++ b/jstests/core/update_arraymatch6.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
var res;
t = db.jstests_update_arraymatch6;
t.drop();
diff --git a/jstests/core/update_arraymatch7.js b/jstests/core/update_arraymatch7.js
index 3ad475f291c..4c0302dbfec 100644
--- a/jstests/core/update_arraymatch7.js
+++ b/jstests/core/update_arraymatch7.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Check that the positional operator works properly when an index only match is used for the update
// query spec. SERVER-5067
diff --git a/jstests/core/update_arraymatch8.js b/jstests/core/update_arraymatch8.js
index d17b837d0ee..7e4eb59f37a 100644
--- a/jstests/core/update_arraymatch8.js
+++ b/jstests/core/update_arraymatch8.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Checking for positional array updates with either .$ or .0 at the end
// SERVER-7511
diff --git a/jstests/core/update_bit_examples.js b/jstests/core/update_bit_examples.js
index 850d64ced5b..adcf6976572 100644
--- a/jstests/core/update_bit_examples.js
+++ b/jstests/core/update_bit_examples.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Basic examples for $bit
var res;
var coll = db.update_bit;
diff --git a/jstests/core/update_blank1.js b/jstests/core/update_blank1.js
index 0a42114ed1c..0777c68c745 100644
--- a/jstests/core/update_blank1.js
+++ b/jstests/core/update_blank1.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.update_blank1;
t.drop();
diff --git a/jstests/core/update_currentdate_examples.js b/jstests/core/update_currentdate_examples.js
index 62ee0220e7d..466ce96e5cc 100644
--- a/jstests/core/update_currentdate_examples.js
+++ b/jstests/core/update_currentdate_examples.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Basic examples for $currentDate
var res;
var coll = db.update_currentdate;
diff --git a/jstests/core/update_dbref.js b/jstests/core/update_dbref.js
index 3cea1415a13..71729c203e5 100644
--- a/jstests/core/update_dbref.js
+++ b/jstests/core/update_dbref.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Test that we can update DBRefs, but not dbref fields outside a DBRef
var res;
diff --git a/jstests/core/update_mul_examples.js b/jstests/core/update_mul_examples.js
index 484c6f7456a..390ae57efd8 100644
--- a/jstests/core/update_mul_examples.js
+++ b/jstests/core/update_mul_examples.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Basic examples for $mul (multiply)
var res;
var coll = db.update_mul;
diff --git a/jstests/core/updatea.js b/jstests/core/updatea.js
index dd54ed04b59..0c7a9e1c504 100644
--- a/jstests/core/updatea.js
+++ b/jstests/core/updatea.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
var res;
t = db.updatea;
diff --git a/jstests/core/updateb.js b/jstests/core/updateb.js
index 1518e7f3546..f90ac62b6c3 100644
--- a/jstests/core/updateb.js
+++ b/jstests/core/updateb.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.updateb;
t.drop();
diff --git a/jstests/core/updated.js b/jstests/core/updated.js
index 919d02610c7..1eaaae3b051 100644
--- a/jstests/core/updated.js
+++ b/jstests/core/updated.js
@@ -1,7 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
t = db.updated;
t.drop();
diff --git a/jstests/core/updatee.js b/jstests/core/updatee.js
index fbbcac01c9a..e2fac8af287 100644
--- a/jstests/core/updatee.js
+++ b/jstests/core/updatee.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// big numeric updates (used to overflow)
t = db.updatee;
diff --git a/jstests/core/updateg.js b/jstests/core/updateg.js
index 8a849a0ce59..908df755376 100644
--- a/jstests/core/updateg.js
+++ b/jstests/core/updateg.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// SERVER-3370 check modifiers with field name characters comparing less than '.' character.
t = db.jstests_updateg;
diff --git a/jstests/core/updateh.js b/jstests/core/updateh.js
index ea1c87582f9..91c985ac014 100644
--- a/jstests/core/updateh.js
+++ b/jstests/core/updateh.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Disallow $ in field names
var res;
diff --git a/jstests/core/updatei.js b/jstests/core/updatei.js
index 54979313195..d5bc3500ab0 100644
--- a/jstests/core/updatei.js
+++ b/jstests/core/updatei.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Test new (optional) update syntax
// SERVER-4176
t = db.updatei;
diff --git a/jstests/core/updatek.js b/jstests/core/updatek.js
index 923b4145d1d..1af9e6112e7 100644
--- a/jstests/core/updatek.js
+++ b/jstests/core/updatek.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Test modifier operations on numerically equivalent string field names. SERVER-4776
t = db.jstests_updatek;
diff --git a/jstests/core/updatem.js b/jstests/core/updatem.js
index 011a33295db..1346a293f66 100644
--- a/jstests/core/updatem.js
+++ b/jstests/core/updatem.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Tests that _id will exist in all updated docs.
t = db.jstests_updatem;
diff --git a/jstests/core/upsert_and.js b/jstests/core/upsert_and.js
index 955b855d525..f99fd995edb 100644
--- a/jstests/core/upsert_and.js
+++ b/jstests/core/upsert_and.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// tests to ensure fields in $and conditions are created when using the query to do upsert
var res;
coll = db.upsert4;
diff --git a/jstests/core/upsert_fields.js b/jstests/core/upsert_fields.js
index 311d6984ce9..910ae6d3e11 100644
--- a/jstests/core/upsert_fields.js
+++ b/jstests/core/upsert_fields.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
//
// Upsert behavior tests for field extraction
//
diff --git a/jstests/core/upsert_shell.js b/jstests/core/upsert_shell.js
index af275d9a7b6..5b7ac501aef 100644
--- a/jstests/core/upsert_shell.js
+++ b/jstests/core/upsert_shell.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// tests to make sure that the new _id is returned after the insert in the shell
var l;
t = db.upsert1;
diff --git a/jstests/core/verify_update_mods.js b/jstests/core/verify_update_mods.js
index c20de299115..efd0beb80cc 100644
--- a/jstests/core/verify_update_mods.js
+++ b/jstests/core/verify_update_mods.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
// Verify update mods exist
var res;
t = db.update_mods;
diff --git a/jstests/core/write_result.js b/jstests/core/write_result.js
index 17c86e7719f..86486089c68 100644
--- a/jstests/core/write_result.js
+++ b/jstests/core/write_result.js
@@ -1,8 +1,3 @@
-// Cannot implicitly shard accessed collections because of following errmsg: A single
-// update/delete on a sharded collection must contain an exact match on _id or contain the shard
-// key.
-// @tags: [assumes_unsharded_collection]
-
//
// Tests the behavior of single writes using write commands
//
diff --git a/jstests/libs/override_methods/implicitly_shard_accessed_collections.js b/jstests/libs/override_methods/implicitly_shard_accessed_collections.js
index a29f68b7323..7b5189c4b33 100644
--- a/jstests/libs/override_methods/implicitly_shard_accessed_collections.js
+++ b/jstests/libs/override_methods/implicitly_shard_accessed_collections.js
@@ -4,9 +4,6 @@
*
* The DB.prototype.getCollection() function is called whenever an undefined property is accessed
* on the db object.
- *
- * DBCollection.prototype.drop() function will re-shard any non-blacklisted collection that is
- * dropped in a sharded cluster.
*/
(function() {
@@ -15,7 +12,6 @@
// Save a reference to the original getCollection method in the IIFE's scope.
// This scoping allows the original method to be called by the getCollection override below.
var originalGetCollection = DB.prototype.getCollection;
- var originalDBCollectionDrop = DBCollection.prototype.drop;
// Blacklisted namespaces that should not be sharded.
var blacklistedNamespaces = [
@@ -25,49 +21,33 @@
/\.system\./,
];
- function shardCollection(collection) {
- var db = collection.getDB();
- var dbName = db.getName();
+ DB.prototype.getCollection = function() {
+ var dbName = this.getName();
+ var collection = originalGetCollection.apply(this, arguments);
var fullName = collection.getFullName();
+ // If the collection exists, there must have been a previous call to getCollection
+ // where we sharded the collection so there's no need to do it again.
+ if (collection.exists()) {
+ return collection;
+ }
+
for (var ns of blacklistedNamespaces) {
if (fullName.match(ns)) {
- return;
+ return collection;
}
}
- var res = db.adminCommand({enableSharding: dbName});
+ var res = this.adminCommand({enableSharding: dbName});
// enableSharding may only be called once for a database.
if (res.code !== ErrorCodes.AlreadyInitialized) {
assert.commandWorked(res, "enabling sharding on the '" + dbName + "' db failed");
}
- res = db.adminCommand({shardCollection: fullName, key: {_id: 'hashed'}});
+ res = this.adminCommand({shardCollection: fullName, key: {_id: 'hashed'}});
assert.commandWorked(res, "sharding '" + fullName + "' with a hashed _id key failed");
- }
-
- DB.prototype.getCollection = function() {
- var collection = originalGetCollection.apply(this, arguments);
-
- // If the collection exists, there must have been a previous call to getCollection
- // where we sharded the collection so there's no need to do it again.
- if (collection.exists()) {
- return collection;
- }
-
- // Attempt to enable sharding on database and collection if not already done.
- shardCollection(collection);
return collection;
};
-
- DBCollection.prototype.drop = function() {
- var dropResult = originalDBCollectionDrop.apply(this, arguments);
-
- // Attempt to enable sharding on database and collection if not already done.
- shardCollection(this);
-
- return dropResult;
- };
}());