[DRIVERS-2761] Avoid Appending Write/Read Concern in Atlas Search Index Helper Commands Created: 02/Nov/23  Updated: 18/Jan/24

Status: Implementing
Project: Drivers
Component/s: Index Management
Fix Version/s: None

Type: Bug Priority: Unknown
Reporter: Slav Babanin Assignee: Kevin Albertson
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Issue split
split to RUBY-3351 Avoid Appending Write/Read Concern in... Backlog
split to GODRIVER-3043 Avoid Appending Write/Read Concern in... Backlog
split to NODE-5745 Avoid Appending Write/Read Concern in... Backlog
split to PYTHON-4037 Avoid Appending Write/Read Concern in... Backlog
split to RUST-1799 Avoid Appending Write/Read Concern in... Backlog
split to CXX-2785 Avoid Appending Write/Read Concern in... Closed
split to MOTOR-1211 Avoid Appending Write/Read Concern in... Closed
split to CSHARP-4839 Avoid Appending Write/Read Concern in... Scheduled
split to CDRIVER-4775 Avoid Appending Write/Read Concern in... Backlog
split to JAVA-5238 Avoid Appending Write/Read Concern in... Backlog
split to PHPLIB-1307 Avoid Appending Write/Read Concern in... Closed
Related
related to JAVA-5233 Avoid Appending Write Concern in Atla... Closed
is related to DRIVERS-2637 Add search index management helpers Closed
Driver Changes: Needed
Downstream Changes Summary:

Summary

Confirm that write/read concern are not applied to Atlas Search Index Helper commands. This is the previously expected behavior, but was previously untested. If write/read concern are applied, omit them to avoid errors from Atlas.

References

New specification tests and prose tests are added in: https://github.com/mongodb/specifications/commit/0b47194538aa817978fae0f77f684f6d5e62ebab
An implementation of the tests and fix in the C++ driver are available here: https://github.com/mongodb/mongo-cxx-driver/pull/1055 with a test follow-up here: https://github.com/mongodb/mongo-cxx-driver/pull/1069

Case:
Engineering Lead: Kevin Albertson Kevin Albertson
Start date:
Driver Compliance:
Key Status/Resolution FixVersion
CDRIVER-4775 Backlog
CXX-2785 Fixed 3.9.0
CSHARP-4839 Scheduled
GODRIVER-3043 Backlog 2.1.0
JAVA-5238 Backlog
NODE-5745 Backlog
MOTOR-1211 Duplicate
PYTHON-4037 Backlog 4.7
PHPLIB-1307 Done 1.17.1
RUBY-3351 Backlog
RUST-1799 Backlog

 Description   

Summary

In the ticket DRIVERS-2637, Atlas Search Index helper methods were introduced.

Later, when some drivers had already implemented the spec, the specification was updated to reflect that write concern is not relevant. From the spec:

These commands internally proxy the search index management commands to a separate process that runs alongside an Atlas cluster. As such, read concern and write concern are not relevant for the search index management commands.

However, some of the drivers might still append write or read concerns to the commands.

Currently, the existing prose tests don't have a specific case to ensure that write/read concerns are not included in the index search commands. This means that some drivers may not be aware that the server will produce an error 

(InvalidOptions) with the message 'Command does not support writeConcern'

 if write/read concern is included. This can lead to errors when users attempt to create Atlas Search Indexes.

Motivation

Who is the affected end user?

The affected end user is any developer or administrator using MongoDB drivers to interact with Atlas Search.

How does this affect the end user?

This affects the end users by potentially causing errors during the creation of Atlas Search Indexes if write/read concerns are inadvertently appended to the commands. Users might be confused or annoyed by these errors.

How likely is it that this problem or use case will occur?

The likelihood of this problem occurring is moderate.

Is this issue urgent?

This issue is moderately urgent as it can lead to errors for users trying to create Atlas Search Indexes.

Is this ticket only for tests?

This ticket primarily addresses a functional improvement by ensuring that write/read concerns are not appended to Atlas Search Index helper commands. 

Acceptance Criteria

  1. When executing Atlas Search Index helper commands, write/read concern must not be appended.
  1. Add a test case to verify that write/read concerns are not appended to Atlas Search Index commands.


 Comments   
Comment by Githook User [ 12/Dec/23 ]

Author:

{'name': 'Kevin Albertson', 'email': 'kevin.albertson@mongodb.com', 'username': 'kevinAlbs'}

Message: DRIVERS-2761 do not apply `readConcern` or `writeConcern` to search index commands (#1474)

  • require not applying read and write concern
  • add prose test with non-default read/write concern
  • unit test each search index management command
  • update changelog
  • Add empty line. Remove double spaces.
  • fix sphinx warning: "Title underline too short"

---------

Co-authored-by: Jérôme Tamarelle <jerome@tamarelle.net>
Branch: master
https://github.com/mongodb/specifications/commit/0b47194538aa817978fae0f77f684f6d5e62ebab

Generated at Thu Feb 08 08:26:21 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.