-
Type: Task
-
Resolution: Duplicate
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: None
-
Service Arch
Allow a mongod started in embedded-router mode to initialize the router's sharding state such that:
- When requests for sharding-initialization commands (addShard, enableSharding, shardCollection) are received on the router port, the router role is able to successfully run these commands.
Note that this will require a few pieces of work:
- Mapping out through experimentation + confirmation with the sharding team what sharding-state needs to be initialized, and what needs to be separately registered between router and shard services (i.e. CatalogCacheLoader, Grid, ShardingState, and any others)
- Performing the dual registration and initialization of any decorations/globals that require separate implementations for shard and router, and removing any non-role-aware accesses
- Writing logic in sharding_initialization and sharding_initialization_mongod that is called from mongod main when embedded router is enabled, that sets up the required state for the router to run the sharding-initialization commands
- Integrating with a test-suite that we produce elsewhere for a single-shard cluster, or writing a noPassthrough test that starts a mongod with embedded router and confirms it can add a shard successfully.
Note that this will likely require multiple commits and separate JIRA tickets/subtasks should be cleaved off. But because I am not exactly sure of the best way to break down the work ahead-of-time, I am creating this ticket as a placeholder/box.
- duplicates
-
SERVER-81316 (SA) Add a test suite for a subset of jscore tests to run against a single-shard cluster
- Closed