[SERVER-61287] IDL compatibility checker mishandles enterprise module Created: 05/Nov/21  Updated: 29/Oct/23  Resolved: 18/Jan/22

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 5.3.0

Type: Bug Priority: Major - P3
Reporter: A. Jesse Jiryu Davis Assignee: Huayu Ouyang
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
is duplicated by SERVER-62742 Complete TODO listed in SERVER-61287 Closed
Related
related to SERVER-62742 Complete TODO listed in SERVER-61287 Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Replication 2021-12-27, Replication 2022-01-10, Replication 2022-01-24
Participants:

 Description   

For each past release tag T, Evergreen runs:

python buildscripts/idl/idl_check_compatibility.py -v --include src --include src/mongo/db/modules/enterprise/src idls/T/src src

Putting the enterprise module on the include path doesn't make sense to me. For IDL files on HEAD, they shouldn't have to import from the enterprise module, otherwise we couldn't build MongoDB without enterprise. And IDL files at T definitely shouldn't import from the enterprise module, unless we check out a past version of it.

I think that when we check compatibility of IDL files in the "mongo" repo we shouldn't list the enterprise module as an include path. Maybe we shouldn't check out the enterprise module at all.

Separately, if we want to check backwards compatibility of IDL changes in enterprise, we should do it with a completely separate run of idl_check_compatibility.py: we should do all the steps we do for "mongo", but just for IDL files in "enterprise": check out past versions of enterprise IDL files and compare them all against the latest enterprise IDL files. Right now I think we don't catch incompatible changes to enterprise-only commands.



 Comments   
Comment by Githook User [ 19/Jan/22 ]

Author:

{'name': 'Huayu Ouyang', 'email': 'huayu.ouyang@mongodb.com', 'username': 'huayu-ouyang'}

Message: SERVER-61287 Remove IDL compatibility checker script TODO
Branch: master
https://github.com/mongodb/mongo/commit/661d4df5bff6b1305c1f316cdd1c661dcbbcd938

Comment by Huayu Ouyang [ 18/Jan/22 ]

Closing this ticket since the check_idl_compat.sh script had already been updated to run 
 $python buildscripts/idl/idl_check_compatibility.py -v --old-include "$dir/src" --old-include "$dir/src/mongo/db/modules/enterprise/src" --new-include src --new-include src/mongo/db/modules/enterprise/src "$dir/src" src as part of SERVER-61288, so it is already checking out and including the old enterprise module correctly.

I also verified on evergreen that we are actually walking the enterprise directory when we check the src directory, so we are already catching incompatible commands in enterprise.

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