summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKaloian Manassiev <kaloian.manassiev@mongodb.com>2022-04-05 13:41:05 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2022-04-05 14:18:25 +0000
commitfbee74f86aff6d7c3110a757b951d575b34cc921 (patch)
treee6034756f9d06c425275ff74e55988f3f94a428f
parentfa32d665bd63de7a9d246fa99df5e30840a931de (diff)
downloadmongo-fbee74f86aff6d7c3110a757b951d575b34cc921.tar.gz
SERVER-65204 Cleanup Router-Only / Router-Shard commands
-rw-r--r--src/mongo/db/s/SConscript41
-rw-r--r--src/mongo/db/s/config/configsvr_clear_jumbo_flag_command.cpp2
-rw-r--r--src/mongo/db/s/config/configsvr_refine_collection_shard_key_command.cpp3
-rw-r--r--src/mongo/db/s/config/configsvr_remove_tags_command.cpp2
-rw-r--r--src/mongo/db/s/refine_collection_shard_key_coordinator.cpp2
-rw-r--r--src/mongo/db/s/remove_tags.idl (renamed from src/mongo/s/request_types/remove_tags.idl)0
-rw-r--r--src/mongo/db/s/sharding_ddl_util.cpp6
-rw-r--r--src/mongo/db/s/shardsvr_merge_chunks_command.cpp (renamed from src/mongo/db/s/merge_chunks_command.cpp)0
-rw-r--r--src/mongo/db/s/shardsvr_refine_collection_shard_key_command.cpp4
-rw-r--r--src/mongo/db/s/shardsvr_split_chunk_command.cpp (renamed from src/mongo/db/s/split_chunk_command.cpp)0
-rw-r--r--src/mongo/s/SConscript3
-rw-r--r--src/mongo/s/commands/SConscript7
-rw-r--r--src/mongo/s/commands/cluster_clear_jumbo_flag_cmd.cpp7
-rw-r--r--src/mongo/s/commands/cluster_commands.idl43
-rw-r--r--src/mongo/s/commands/cluster_enable_sharding_cmd.cpp2
-rw-r--r--src/mongo/s/commands/cluster_refine_collection_shard_key_cmd.cpp4
-rw-r--r--src/mongo/s/commands/refine_collection_shard_key.idl (renamed from src/mongo/s/request_types/refine_collection_shard_key.idl)23
-rw-r--r--src/mongo/s/request_types/clear_jumbo_flag.idl76
-rw-r--r--src/mongo/s/request_types/sharded_ddl_commands.idl64
19 files changed, 127 insertions, 162 deletions
diff --git a/src/mongo/db/s/SConscript b/src/mongo/db/s/SConscript
index c407df26173..45a68eafca0 100644
--- a/src/mongo/db/s/SConscript
+++ b/src/mongo/db/s/SConscript
@@ -261,6 +261,7 @@ env.Library(
'dist_lock_catalog.cpp',
'dist_lock_manager_replset.cpp',
'dist_lock_manager.cpp',
+ 'remove_tags.idl',
'sharding_config_server_parameters.idl',
'sharding_ddl_util.cpp',
'sharding_util.cpp',
@@ -318,21 +319,15 @@ env.Library(
'cluster_getmore_cmd_d.cpp',
'cluster_pipeline_cmd_d.cpp',
'cluster_write_cmd_d.cpp',
- 'collmod_coordinator.cpp',
'collmod_coordinator_document.idl',
'collmod_coordinator_pre60_compatible.cpp',
+ 'collmod_coordinator.cpp',
'compact_structured_encryption_data_coordinator.cpp',
'compact_structured_encryption_data_coordinator.idl',
- 'config/set_cluster_parameter_coordinator.cpp',
- 'config/set_cluster_parameter_coordinator_document.idl',
- 'config/set_user_write_block_mode_coordinator.cpp',
- 'config/set_user_write_block_mode_coordinator_document.idl',
'config/configsvr_abort_reshard_collection_command.cpp',
'config/configsvr_add_shard_command.cpp',
'config/configsvr_add_shard_to_zone_command.cpp',
'config/configsvr_balancer_collection_status_command.cpp',
- 'config/configsvr_set_user_write_block_mode_command.cpp',
- 'config/configsvr_set_cluster_parameter_command.cpp',
'config/configsvr_cleanup_reshard_collection_command.cpp',
'config/configsvr_clear_jumbo_flag_command.cpp',
'config/configsvr_collmod_command.cpp',
@@ -340,9 +335,9 @@ env.Library(
'config/configsvr_commit_reshard_collection_command.cpp',
'config/configsvr_configure_collection_balancing.cpp',
'config/configsvr_control_balancer_command.cpp',
- 'config/configsvr_coordinator.idl',
'config/configsvr_coordinator_service.cpp',
'config/configsvr_coordinator.cpp',
+ 'config/configsvr_coordinator.idl',
'config/configsvr_create_database_command.cpp',
'config/configsvr_ensure_chunk_version_is_greater_than_command.cpp',
'config/configsvr_merge_chunks_command.cpp',
@@ -354,48 +349,53 @@ env.Library(
'config/configsvr_remove_shard_from_zone_command.cpp',
'config/configsvr_remove_tags_command.cpp',
'config/configsvr_rename_collection_metadata_command.cpp',
- 'config/configsvr_reshard_collection_cmd.cpp',
'config/configsvr_repair_sharded_collection_chunks_history_command.cpp',
+ 'config/configsvr_reshard_collection_cmd.cpp',
'config/configsvr_run_restore_command.cpp',
'config/configsvr_set_allow_migrations_command.cpp',
+ 'config/configsvr_set_cluster_parameter_command.cpp',
+ 'config/configsvr_set_user_write_block_mode_command.cpp',
'config/configsvr_split_chunk_command.cpp',
'config/configsvr_update_zone_key_range_command.cpp',
- 'create_collection_coordinator.cpp',
+ 'config/set_cluster_parameter_coordinator_document.idl',
+ 'config/set_cluster_parameter_coordinator.cpp',
+ 'config/set_user_write_block_mode_coordinator_document.idl',
+ 'config/set_user_write_block_mode_coordinator.cpp',
'create_collection_coordinator_document.idl',
- 'drop_collection_coordinator.cpp',
+ 'create_collection_coordinator.cpp',
'drop_collection_coordinator_document.idl',
- 'drop_database_coordinator.cpp',
+ 'drop_collection_coordinator.cpp',
'drop_database_coordinator_document.idl',
+ 'drop_database_coordinator.cpp',
'flush_database_cache_updates_command.cpp',
'flush_resharding_state_change_command.cpp',
'flush_routing_table_cache_updates_command.cpp',
'get_database_version_command.cpp',
'get_shard_version_command.cpp',
'get_stats_for_balancing.idl',
- 'merge_chunks_command.cpp',
'migration_chunk_cloner_source_legacy_commands.cpp',
'migration_destination_manager_legacy_commands.cpp',
- 'move_primary_coordinator.cpp',
'move_primary_coordinator_document.idl',
+ 'move_primary_coordinator.cpp',
'participant_block.idl',
+ 'refine_collection_shard_key_coordinator_document.idl',
+ 'refine_collection_shard_key_coordinator.cpp',
'remove_chunks.idl',
'rename_collection_coordinator.cpp',
'rename_collection_participant_service.cpp',
- 'refine_collection_shard_key_coordinator.cpp',
- 'refine_collection_shard_key_coordinator_document.idl',
- 'reshard_collection_coordinator.cpp',
'reshard_collection_coordinator_document.idl',
+ 'reshard_collection_coordinator.cpp',
'resharding_test_commands.cpp',
'resharding_test_commands.idl',
- 'set_allow_migrations_coordinator.cpp',
'set_allow_migrations_coordinator_document.idl',
+ 'set_allow_migrations_coordinator.cpp',
'set_shard_version_command.cpp',
'sharded_collmod.idl',
'sharded_index_consistency_server_status.cpp',
'sharded_rename_collection.idl',
+ 'sharding_ddl_coordinator_service.cpp',
'sharding_ddl_coordinator.cpp',
'sharding_ddl_coordinator.idl',
- 'sharding_ddl_coordinator_service.cpp',
'sharding_server_status.cpp',
'sharding_state_command.cpp',
'shardsvr_abort_reshard_collection_command.cpp',
@@ -412,6 +412,7 @@ env.Library(
'shardsvr_drop_database_command.cpp',
'shardsvr_drop_database_participant_command.cpp',
'shardsvr_get_stats_for_balancing_command.cpp',
+ 'shardsvr_merge_chunks_command.cpp',
'shardsvr_move_primary_command.cpp',
'shardsvr_move_range_command.cpp',
'shardsvr_participant_block_command.cpp',
@@ -422,7 +423,7 @@ env.Library(
'shardsvr_resharding_operation_time_command.cpp',
'shardsvr_set_allow_migrations_command.cpp',
'shardsvr_set_user_write_block_mode_command.cpp',
- 'split_chunk_command.cpp',
+ 'shardsvr_split_chunk_command.cpp',
'split_vector_command.cpp',
'txn_two_phase_commit_cmds.cpp',
'wait_for_ongoing_chunk_splits_command.cpp',
diff --git a/src/mongo/db/s/config/configsvr_clear_jumbo_flag_command.cpp b/src/mongo/db/s/config/configsvr_clear_jumbo_flag_command.cpp
index f97d164151b..c87f8884cee 100644
--- a/src/mongo/db/s/config/configsvr_clear_jumbo_flag_command.cpp
+++ b/src/mongo/db/s/config/configsvr_clear_jumbo_flag_command.cpp
@@ -38,7 +38,7 @@
#include "mongo/db/s/config/sharding_catalog_manager.h"
#include "mongo/db/s/dist_lock_manager.h"
#include "mongo/s/grid.h"
-#include "mongo/s/request_types/clear_jumbo_flag_gen.h"
+#include "mongo/s/request_types/sharded_ddl_commands_gen.h"
namespace mongo {
namespace {
diff --git a/src/mongo/db/s/config/configsvr_refine_collection_shard_key_command.cpp b/src/mongo/db/s/config/configsvr_refine_collection_shard_key_command.cpp
index dac1c59a240..22966a769fa 100644
--- a/src/mongo/db/s/config/configsvr_refine_collection_shard_key_command.cpp
+++ b/src/mongo/db/s/config/configsvr_refine_collection_shard_key_command.cpp
@@ -37,7 +37,7 @@
#include "mongo/db/s/shard_key_util.h"
#include "mongo/logv2/log.h"
#include "mongo/s/grid.h"
-#include "mongo/s/request_types/refine_collection_shard_key_gen.h"
+#include "mongo/s/request_types/sharded_ddl_commands_gen.h"
#include "mongo/s/stale_shard_version_helpers.h"
namespace mongo {
@@ -176,6 +176,7 @@ public:
AllowedOnSecondary secondaryAllowed(ServiceContext*) const override {
return AllowedOnSecondary::kNever;
}
+
} configsvrRefineCollectionShardKeyCmd;
} // namespace
diff --git a/src/mongo/db/s/config/configsvr_remove_tags_command.cpp b/src/mongo/db/s/config/configsvr_remove_tags_command.cpp
index ce1afe24e15..8305df53603 100644
--- a/src/mongo/db/s/config/configsvr_remove_tags_command.cpp
+++ b/src/mongo/db/s/config/configsvr_remove_tags_command.cpp
@@ -36,12 +36,12 @@
#include "mongo/db/commands.h"
#include "mongo/db/dbdirectclient.h"
#include "mongo/db/repl/repl_client_info.h"
+#include "mongo/db/s/remove_tags_gen.h"
#include "mongo/db/session_catalog_mongod.h"
#include "mongo/db/transaction_participant.h"
#include "mongo/s/catalog/sharding_catalog_client.h"
#include "mongo/s/catalog/type_tags.h"
#include "mongo/s/grid.h"
-#include "mongo/s/request_types/remove_tags_gen.h"
namespace mongo {
namespace {
diff --git a/src/mongo/db/s/refine_collection_shard_key_coordinator.cpp b/src/mongo/db/s/refine_collection_shard_key_coordinator.cpp
index 919b85ca10f..3d90db4e497 100644
--- a/src/mongo/db/s/refine_collection_shard_key_coordinator.cpp
+++ b/src/mongo/db/s/refine_collection_shard_key_coordinator.cpp
@@ -40,7 +40,7 @@
#include "mongo/logv2/log.h"
#include "mongo/s/catalog_cache.h"
#include "mongo/s/grid.h"
-#include "mongo/s/request_types/refine_collection_shard_key_gen.h"
+#include "mongo/s/request_types/sharded_ddl_commands_gen.h"
namespace mongo {
diff --git a/src/mongo/s/request_types/remove_tags.idl b/src/mongo/db/s/remove_tags.idl
index c0d91aae56c..c0d91aae56c 100644
--- a/src/mongo/s/request_types/remove_tags.idl
+++ b/src/mongo/db/s/remove_tags.idl
diff --git a/src/mongo/db/s/sharding_ddl_util.cpp b/src/mongo/db/s/sharding_ddl_util.cpp
index 8a0c739d051..741bbca1f42 100644
--- a/src/mongo/db/s/sharding_ddl_util.cpp
+++ b/src/mongo/db/s/sharding_ddl_util.cpp
@@ -29,8 +29,6 @@
#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kSharding
-#include "mongo/platform/basic.h"
-
#include "mongo/db/s/sharding_ddl_util.h"
#include "mongo/db/catalog/collection_catalog.h"
@@ -39,6 +37,7 @@
#include "mongo/db/dbdirectclient.h"
#include "mongo/db/repl/repl_client_info.h"
#include "mongo/db/s/collection_sharding_runtime.h"
+#include "mongo/db/s/remove_tags_gen.h"
#include "mongo/db/s/shard_filtering_metadata_refresh.h"
#include "mongo/db/s/sharding_logging.h"
#include "mongo/db/s/sharding_util.h"
@@ -51,14 +50,11 @@
#include "mongo/s/catalog/type_collection.h"
#include "mongo/s/catalog/type_tags.h"
#include "mongo/s/grid.h"
-#include "mongo/s/request_types/remove_tags_gen.h"
#include "mongo/s/request_types/set_allow_migrations_gen.h"
#include "mongo/s/write_ops/batch_write_exec.h"
namespace mongo {
-
namespace sharding_ddl_util {
-
namespace {
void updateTags(OperationContext* opCtx,
diff --git a/src/mongo/db/s/merge_chunks_command.cpp b/src/mongo/db/s/shardsvr_merge_chunks_command.cpp
index 6792234c9fd..6792234c9fd 100644
--- a/src/mongo/db/s/merge_chunks_command.cpp
+++ b/src/mongo/db/s/shardsvr_merge_chunks_command.cpp
diff --git a/src/mongo/db/s/shardsvr_refine_collection_shard_key_command.cpp b/src/mongo/db/s/shardsvr_refine_collection_shard_key_command.cpp
index ed3f7c0b0ad..7a7fa8fceac 100644
--- a/src/mongo/db/s/shardsvr_refine_collection_shard_key_command.cpp
+++ b/src/mongo/db/s/shardsvr_refine_collection_shard_key_command.cpp
@@ -35,7 +35,6 @@
#include "mongo/db/s/refine_collection_shard_key_coordinator.h"
#include "mongo/db/s/sharding_state.h"
#include "mongo/s/refine_collection_shard_key_coordinator_feature_flags_gen.h"
-#include "mongo/s/request_types/refine_collection_shard_key_gen.h"
#include "mongo/s/request_types/sharded_ddl_commands_gen.h"
namespace mongo {
@@ -104,7 +103,8 @@ public:
return request().getNamespace();
}
};
-} shardsvrDropDatabaseCommand;
+
+} shardsvrRefineCollectionShardKeyCommand;
} // namespace
} // namespace mongo
diff --git a/src/mongo/db/s/split_chunk_command.cpp b/src/mongo/db/s/shardsvr_split_chunk_command.cpp
index 5476c28e787..5476c28e787 100644
--- a/src/mongo/db/s/split_chunk_command.cpp
+++ b/src/mongo/db/s/shardsvr_split_chunk_command.cpp
diff --git a/src/mongo/s/SConscript b/src/mongo/s/SConscript
index bfc36af2a0f..cc5e33d5311 100644
--- a/src/mongo/s/SConscript
+++ b/src/mongo/s/SConscript
@@ -192,7 +192,6 @@ env.Library(
'request_types/balance_chunk_request_type.cpp',
'request_types/balancer_collection_status.idl',
'request_types/cleanup_reshard_collection.idl',
- 'request_types/clear_jumbo_flag.idl',
'request_types/clone_catalog_data.idl',
'request_types/commit_chunk_migration_request_type.cpp',
'request_types/commit_reshard_collection.idl',
@@ -208,9 +207,7 @@ env.Library(
'request_types/move_chunk_request.cpp',
'request_types/move_primary.idl',
'request_types/move_range_request.idl',
- 'request_types/refine_collection_shard_key.idl',
'request_types/remove_shard_from_zone_request_type.cpp',
- 'request_types/remove_tags.idl',
'request_types/reshard_collection.idl',
'request_types/resharding_operation_time.idl',
'request_types/set_allow_migrations.idl',
diff --git a/src/mongo/s/commands/SConscript b/src/mongo/s/commands/SConscript
index d80e09c82d3..0a1796119aa 100644
--- a/src/mongo/s/commands/SConscript
+++ b/src/mongo/s/commands/SConscript
@@ -31,13 +31,13 @@ env.Library(
source=[
'cluster_abort_reshard_collection_cmd.cpp',
'cluster_abort_transaction_cmd_s.cpp',
- 'cluster_oplog_note_cmd.cpp',
'cluster_available_query_options_cmd.cpp',
'cluster_build_info.cpp',
'cluster_change_stream_options_command.cpp',
'cluster_cleanup_reshard_collection_cmd.cpp',
'cluster_coll_stats_cmd.cpp',
'cluster_collection_mod_cmd.cpp',
+ 'cluster_commands.idl',
'cluster_commit_reshard_collection_cmd.cpp',
'cluster_commit_transaction_cmd_s.cpp',
'cluster_compact_cmd.cpp',
@@ -64,9 +64,9 @@ env.Library(
'cluster_get_last_error_cmd.cpp',
'cluster_get_shard_version_cmd.cpp',
'cluster_getmore_cmd_s.cpp',
+ 'cluster_hello_cmd.cpp',
'cluster_index_filter_cmd.cpp',
'cluster_is_db_grid_cmd.cpp',
- 'cluster_hello_cmd.cpp',
'cluster_kill_op.cpp',
'cluster_killcursors_cmd.cpp',
'cluster_killoperations_cmd.cpp',
@@ -77,6 +77,7 @@ env.Library(
'cluster_map_reduce_cmd.cpp',
'cluster_multicast_cmd.cpp',
'cluster_netstat_cmd.cpp',
+ 'cluster_oplog_note_cmd.cpp',
'cluster_pipeline_cmd_s.cpp',
'cluster_plan_cache_clear_cmd.cpp',
'cluster_profile_cmd.cpp',
@@ -99,8 +100,8 @@ env.Library(
'cluster_whats_my_uri_cmd.cpp',
'cluster_write_cmd_s.cpp',
'kill_sessions_remote.cpp',
+ 'refine_collection_shard_key.idl',
's_read_write_concern_defaults_server_status.cpp',
- 'cluster_commands.idl',
'shard_collection.idl',
],
LIBDEPS_PRIVATE=[
diff --git a/src/mongo/s/commands/cluster_clear_jumbo_flag_cmd.cpp b/src/mongo/s/commands/cluster_clear_jumbo_flag_cmd.cpp
index 0750a0b4b47..87a742fee78 100644
--- a/src/mongo/s/commands/cluster_clear_jumbo_flag_cmd.cpp
+++ b/src/mongo/s/commands/cluster_clear_jumbo_flag_cmd.cpp
@@ -39,17 +39,16 @@
#include "mongo/db/auth/authorization_session.h"
#include "mongo/db/commands.h"
#include "mongo/s/catalog_cache.h"
-#include "mongo/s/client/shard_registry.h"
-#include "mongo/s/cluster_commands_helpers.h"
+#include "mongo/s/commands/cluster_commands_gen.h"
#include "mongo/s/grid.h"
-#include "mongo/s/request_types/clear_jumbo_flag_gen.h"
+#include "mongo/s/request_types/sharded_ddl_commands_gen.h"
namespace mongo {
namespace {
class ClearJumboFlagCommand final : public TypedCommand<ClearJumboFlagCommand> {
public:
- using Request = ClearJumboFlag;
+ using Request = ClusterClearJumboFlag;
class Invocation : public MinimalInvocationBase {
public:
diff --git a/src/mongo/s/commands/cluster_commands.idl b/src/mongo/s/commands/cluster_commands.idl
index 88371a54484..26d5ad8760c 100644
--- a/src/mongo/s/commands/cluster_commands.idl
+++ b/src/mongo/s/commands/cluster_commands.idl
@@ -31,6 +31,7 @@ global:
imports:
- "mongo/idl/basic_types.idl"
+ - "mongo/s/sharding_types.idl"
server_parameters:
KillSessionsMaxConcurrency:
@@ -50,6 +51,7 @@ server_parameters:
default: 60000
structs:
+
ClusterMulticast:
description: "A struct representing the 'multicast' command's arguments"
strict: false
@@ -64,3 +66,44 @@ structs:
timeout:
type: int
optional: true
+
+commands:
+
+ createDatabase:
+ description: "The public enableSharding command on mongos."
+ command_name: enableSharding
+ command_alias: enablesharding
+ cpp_name: ClusterCreateDatabase
+ strict: false
+ namespace: type
+ type: string
+ api_version: ""
+ reply_type: OkReply
+ fields:
+ primaryShard:
+ type: shard_id
+ description: "If set, indicates to the system which shard should be used as the
+ primary for the database (if not already created). Otherwise, the
+ system will use the balancer in order to select a primary."
+ optional: true
+
+ clearJumboFlag:
+ description: "The public clearJumboFlag command on mongos."
+ command_name: clearJumboFlag
+ cpp_name: ClusterClearJumboFlag
+ strict: false
+ namespace: type
+ api_version: ""
+ type: namespacestring
+ reply_type: OkReply
+ fields:
+ bounds:
+ type: array<object>
+ description: "The exact boundaries for a single chunk."
+ optional: true
+
+ find:
+ type: object
+ description: "The shard key value that is within a chunk's boundaries.
+ Cannot be used on collections with hashed shard keys."
+ optional: true
diff --git a/src/mongo/s/commands/cluster_enable_sharding_cmd.cpp b/src/mongo/s/commands/cluster_enable_sharding_cmd.cpp
index 64229494823..1dbb6ad427d 100644
--- a/src/mongo/s/commands/cluster_enable_sharding_cmd.cpp
+++ b/src/mongo/s/commands/cluster_enable_sharding_cmd.cpp
@@ -34,9 +34,9 @@
#include "mongo/db/auth/authorization_session.h"
#include "mongo/db/commands.h"
#include "mongo/s/catalog_cache.h"
+#include "mongo/s/commands/cluster_commands_gen.h"
#include "mongo/s/grid.h"
#include "mongo/s/request_types/sharded_ddl_commands_gen.h"
-#include "mongo/util/scopeguard.h"
namespace mongo {
namespace {
diff --git a/src/mongo/s/commands/cluster_refine_collection_shard_key_cmd.cpp b/src/mongo/s/commands/cluster_refine_collection_shard_key_cmd.cpp
index 30ec8e0932f..e1cfdb65d3e 100644
--- a/src/mongo/s/commands/cluster_refine_collection_shard_key_cmd.cpp
+++ b/src/mongo/s/commands/cluster_refine_collection_shard_key_cmd.cpp
@@ -29,15 +29,13 @@
#define MONGO_LOGV2_DEFAULT_COMPONENT ::mongo::logv2::LogComponent::kCommand
-#include "mongo/platform/basic.h"
-
#include "mongo/db/auth/authorization_session.h"
#include "mongo/db/commands.h"
#include "mongo/logv2/log.h"
#include "mongo/rpc/get_status_from_command_result.h"
#include "mongo/s/cluster_commands_helpers.h"
+#include "mongo/s/commands/refine_collection_shard_key_gen.h"
#include "mongo/s/grid.h"
-#include "mongo/s/request_types/refine_collection_shard_key_gen.h"
#include "mongo/s/request_types/sharded_ddl_commands_gen.h"
#include "mongo/util/fail_point.h"
diff --git a/src/mongo/s/request_types/refine_collection_shard_key.idl b/src/mongo/s/commands/refine_collection_shard_key.idl
index ff9408a34fd..c77a44a1725 100644
--- a/src/mongo/s/request_types/refine_collection_shard_key.idl
+++ b/src/mongo/s/commands/refine_collection_shard_key.idl
@@ -57,26 +57,3 @@ commands:
the shard key pattern if unique is true. If true then it will verify and if
false then it won't.
type: optionalBool
-
- _configsvrRefineCollectionShardKey:
- command_name: _configsvrRefineCollectionShardKey
- cpp_name: ConfigsvrRefineCollectionShardKey
- description: "The internal refineCollectionShardKey command on the config server"
- strict: false
- namespace: type
- api_version: ""
- type: namespacestring
- fields:
- key:
- type: object
- description: "The index specification document to use as the new shard key."
- optional: false
- epoch:
- type: objectid
- description: "The expected epoch of the namespace provided to
- refineCollectionShardKey."
- optional: false
- enforceUniquenessCheck:
- description: >-
- Verifies that the shard key index has the same unique setting as the command.
- type: optionalBool
diff --git a/src/mongo/s/request_types/clear_jumbo_flag.idl b/src/mongo/s/request_types/clear_jumbo_flag.idl
deleted file mode 100644
index 199a5f67631..00000000000
--- a/src/mongo/s/request_types/clear_jumbo_flag.idl
+++ /dev/null
@@ -1,76 +0,0 @@
-# Copyright (C) 2019-present MongoDB, Inc.
-#
-# This program is free software: you can redistribute it and/or modify
-# it under the terms of the Server Side Public License, version 1,
-# as published by MongoDB, Inc.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# Server Side Public License for more details.
-#
-# You should have received a copy of the Server Side Public License
-# along with this program. If not, see
-# <http://www.mongodb.com/licensing/server-side-public-license>.
-#
-# As a special exception, the copyright holders give permission to link the
-# code of portions of this program with the OpenSSL library under certain
-# conditions as described in each individual source file and distribute
-# linked combinations including the program with the OpenSSL library. You
-# must comply with the Server Side Public License in all respects for
-# all of the code used other than as permitted herein. If you modify file(s)
-# with this exception, you may extend this exception to your version of the
-# file(s), but you are not obligated to do so. If you do not wish to do so,
-# delete this exception statement from your version. If you delete this
-# exception statement from all source files in the program, then also delete
-# it in the license file.
-#
-
-# clearJumboFlag IDL File
-
-global:
- cpp_namespace: "mongo"
-
-imports:
- - "mongo/idl/basic_types.idl"
-
-commands:
- clearJumboFlag:
- description: "clearJumboFlag command for mongos"
- command_name: clearJumboFlag
- namespace: type
- api_version: ""
- type: namespacestring
- strict: false
- fields:
- bounds:
- type: array<object>
- description: "The exact boundaries for a single chunk."
- optional: true
-
- find:
- type: object
- description: "The shard key value that is within a chunk's boundaries.
- Cannot be used on collections with hashed shard keys."
- optional: true
-
- _configsvrClearJumboFlag:
- command_name: _configsvrClearJumboFlag
- cpp_name: ConfigsvrClearJumboFlag
- description: "internal clearJumboFlag command for config server"
- namespace: type
- api_version: ""
- type: namespacestring
- strict: false
- fields:
- epoch:
- type: objectid
- description: "The expected epoch of the namespace provided to
- clearJumboFlag."
- optional: false
- minKey:
- type: object
- description: "The lower bound key value of the chunk."
- maxKey:
- type: object
- description: "The upper bound key value of the chunk."
diff --git a/src/mongo/s/request_types/sharded_ddl_commands.idl b/src/mongo/s/request_types/sharded_ddl_commands.idl
index 110b3e1bc87..fd0a7a1946f 100644
--- a/src/mongo/s/request_types/sharded_ddl_commands.idl
+++ b/src/mongo/s/request_types/sharded_ddl_commands.idl
@@ -26,6 +26,8 @@
# it in the license file.
#
+# Contains internal DDL commands which are exchanged between Router and Shard/ConfigServer role and are linked both on MongoD and MongoS
+
global:
cpp_namespace: "mongo"
cpp_includes:
@@ -245,24 +247,6 @@ structs:
commands:
- clusterCreateDatabase:
- description: "The public enableSharding command on mongos."
- command_name: enableSharding
- command_alias: enablesharding
- cpp_name: ClusterCreateDatabase
- strict: false
- namespace: type
- type: string
- api_version: ""
- reply_type: OkReply
- fields:
- primaryShard:
- type: shard_id
- description: "If set, indicates to the system which shard should be used as the
- primary for the database (if not already created). Otherwise, the
- system will use the balancer in order to select a primary."
- optional: true
-
_shardsvrCreateCollection:
command_name: _shardsvrCreateCollection
cpp_name: ShardsvrCreateCollection
@@ -388,6 +372,29 @@ commands:
chained_structs:
RefineCollectionShardKeyRequest: RefineCollectionShardKeyRequest
+ _configsvrRefineCollectionShardKey:
+ command_name: _configsvrRefineCollectionShardKey
+ cpp_name: ConfigsvrRefineCollectionShardKey
+ description: "The internal refineCollectionShardKey command on the config server"
+ strict: false
+ namespace: type
+ api_version: ""
+ type: namespacestring
+ fields:
+ key:
+ type: object
+ description: "The index specification document to use as the new shard key."
+ optional: false
+ epoch:
+ type: objectid
+ description: "The expected epoch of the namespace provided to
+ refineCollectionShardKey."
+ optional: false
+ enforceUniquenessCheck:
+ description: >-
+ Verifies that the shard key index has the same unique setting as the command.
+ type: optionalBool
+
_configsvrCreateDatabase:
description: "The internal createDatabase command on the config server"
api_version: ""
@@ -456,3 +463,24 @@ commands:
type: object_owned
api_version: ""
strict: false
+
+ _configsvrClearJumboFlag:
+ command_name: _configsvrClearJumboFlag
+ cpp_name: ConfigsvrClearJumboFlag
+ description: "internal clearJumboFlag command for config server"
+ namespace: type
+ api_version: ""
+ type: namespacestring
+ strict: false
+ fields:
+ epoch:
+ type: objectid
+ description: "The expected epoch of the namespace provided to
+ clearJumboFlag."
+ optional: false
+ minKey:
+ type: object
+ description: "The lower bound key value of the chunk."
+ maxKey:
+ type: object
+ description: "The upper bound key value of the chunk."