Hi Team,
Currently, the “overwrite” write mode drops the target collection and then proceeds to insert data into the collection.
The problem is that when it recreates the collection it does so with default options and that creates problems for the following example scenarios:
- Sharded Collections: as the new collection is not sharded anymore.
- Collections with non-default collations
- Time-series collections
There may be others but these are the ones I could come up with. The intention behind this improvement request is that we add the appropriate functionality so that the "overwrite" mode recreates the collection with the same exact options as it was created.
Otherwise this mode is rendered useless for several use cases.
Regards
Diego