[DOCS-11387] Docs for SERVER-32635: Provide a framework to ensure a last stable binary version mongos crashes when attempting to connect to a latest featureCompatibilityVersion sharded cluster for all last stable binary versions >= 3.8 Created: 02/Mar/18  Updated: 29/Oct/23  Resolved: 29/Jun/18

Status: Closed
Project: Documentation
Component/s: None
Affects Version/s: None
Fix Version/s: 3.7.3

Type: Task Priority: Major - P3
Reporter: Kay Kim (Inactive) Assignee: Kay Kim (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Documented
documents SERVER-32635 Provide a framework to ensure a last ... Closed
Related
related to DOCS-11840 fcv/binary version and mongos Closed
Participants:
Days since reply: 5 years, 32 weeks, 5 days ago
Epic Link: DOCS: 4.0 Server

 Description   

Documentation Request Summary:

This ticket makes the mongos crash when it communicates with a server that has been upgrade both a binary and feature compatibility version higher than itself. So a mongos v4.0 talking to a v4.2 mongod with feature compatibility version 4.2 – a v4.2 mongod with FCV 4.0 will not cause a crash, to be clear.

This kind of scenario can happen when a user forgets to upgrade the mongos binary and then calls setFCV(upgrade), leaving the still downgraded mongos unable to communicate. Rather than the mongos logging incompatible server version errors endlessly, we've chosen to crash it.

Engineering Ticket Description:

If a last-stable binary version mongos attempts to point to a latest featureCompatibilityVersion sharded cluster, the mongos will spin, repeatedly attempting to connect and failing with IncompatibleServerVersion errors. Instead, the mongos should crash in this scenario. This framework should be available for all last-stable binary versions >= 3.8. This implementation should not cause a latest binary version mongos to crash upon attempting to connect to a last stable binary version node.
A proposed implementation for the framework follows:
The validateWireVersion function in protocol.cpp can be modified to have a new error code that is returned when the client's maximum wireVersion is less than the server's minimum wireVersion. If the client is a mongos and it sees this error upon calling validateWireVersion, it will crash. The client can use the isMongos() function to determine whether it is a mongos.This low-level implementation is justifiable because a last-stable mongos should crash upon any attempts to connect to a latest featureCompatibilityVersion node in the cluster. This implementation assumes a mongos will only be a client to other members of the same sharded cluster and not to members of a different sharded cluster.



 Comments   
Comment by Githook User [ 29/Jun/18 ]

Author:

{'username': 'kay-kim', 'name': 'kay', 'email': 'kay.kim@10gen.com'}

Message: DOCS-11387: mongos and fcv
Branch: master
https://github.com/mongodb/docs/commit/57c8003ec9d02f36687c914133e48274dc272f38

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