[SERVER-61261] Misleading error message from fcv idl parser. Created: 04/Nov/21  Updated: 29/Oct/23  Resolved: 15/Nov/21

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 5.2.0-rc0

Type: Bug Priority: Major - P3
Reporter: Suganthi Mani Assignee: Suganthi Mani
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Server Serverless 2021-11-15, Server Serverless 2021-11-29
Participants:

 Description   

The type: fcv_string is been used in couple of different idls other than the idl that defines feature compatibility version document schema  for admin.system.version collection. For e.g, setFeatureCompatibilityVersion cmd  & tenant migration state document have fields uses this fcv_string type. In case parsing those fcv type fields fails, we through a misleading error message.

Running adminDB.adminCommand({setFeatureCompatibilityVersion: "4.9"} on  5.2 binary will throw an error msg as "Invalid value for featureCompatibilityVersiondocument in admin.system.version, found 4.9, expected '5.0' or '5.1' or '5.2'. 

I think we need to make the error message as generic.



 Comments   
Comment by Githook User [ 15/Nov/21 ]

Author:

{'name': 'Suganthi Mani', 'email': 'suganthi.mani@mongodb.com', 'username': 'smani87'}

Message: SERVER-61261 "fcv_string" idl type's serializer and deserializer throws generic error message on validation failure.
Branch: master
https://github.com/mongodb/mongo/commit/8c73fa4df6d30a7ded2d31f4412601403838d945

Generated at Thu Feb 08 05:51:58 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.