[SERVER-24125] Write test that converts existing replica set to a sharded cluster and back Created: 10/May/16  Updated: 25/Jan/17  Resolved: 20/Aug/16

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: None
Fix Version/s: 3.3.12

Type: Task Priority: Major - P3
Reporter: Spencer Brody (Inactive) Assignee: Randolph Tan
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Sprint: Sharding 18 (08/05/16), Sharding 2016-08-29
Participants:

 Description   

It is supported to upgrade an existing unsharded deployment to a sharded one without downtime and vice versa. We should have a jstest that tests this to ensure we never accidentally break that process



 Comments   
Comment by Githook User [ 20/Aug/16 ]

Author:

{u'username': u'renctan', u'name': u'Randolph Tan', u'email': u'randolph@10gen.com'}

Message: SERVER-24125 Write test that converts existing replica set to a sharded cluster and back
Branch: master
https://github.com/mongodb/mongo/commit/0b1cb011c860aa8c68714d4370c30417009993ed

Comment by Spencer Brody (Inactive) [ 08/Aug/16 ]

Proposed test structure:
Set up a regular replica set, insert some data into at least 2 collections.
Do a rolling restart to give all nodes --shardsvr
Spin up a config server replset and a mongos, add the existing replset as a shard.
Shard one of the collections, leave the other unsharded
Spin up a new replica set, add it as a second shard, wait for chunks to be balanced.
Remove the newly added shard (will involve waiting for chunks to drain to the original shard).
Rolling restart the remaining shard to remove --shardsvr
Shut down the mongos and config servers

At every phase in this process be doing some basic CRUD ops to verify that everything is still working fine.

Generated at Thu Feb 08 04:05:27 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.