0
votes

I have a project that has been working in a single server environment but now I want to introduce sharding. I guess an offline migration is inevitable in this case. I struggle to find any example in this regards, seems like very few people use sharding in RavenDb.

As I understand the basic idea is to retrieve all documents you want to shard from single-server document store and store them into a new sharded document store (so each document is put to an appropriate shard). Do I miss anything? An example would be highly appreciated.

1

1 Answers

1
votes

The easiest way would be to read it all from the single server and write it to the sharded store, yes.

Alternatively, you can manually move the data and make sure that the sharding strategy you use handle it, but that is more complex.