CXX-2785 do not apply readConcern
or writeConcern
to search index commands
#1055
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Do not apply
readConcern
orwriteConcern
to search index commandsTests verified with this patch: https://spruce.mongodb.com/version/654b89333e8e86f7a940c6e3
Background & Motivation
This is a follow-up to #986
Search index commands return an error if
readConcern
orwriteConcern
is included.Prior to the fix, applying a non-default
readConcern
orwriteConcern
to themongocxx::collection
,mongocxx::database
, ormongocxx::client
resulted in thereadConcern
orwriteConcern
being included in the search index command.Prior to the fix, the added test "create and list search indexes with non-default readConcern and writeConcern" fails when run against an Atlas cluster:
These changes are intended to be included in 3.9.0. The API added in #986 has not yet been released. The error may give a poor user experience.
The new tests are specified in mongodb/specifications#1474.