[SERVER-84253] Refactor MultitenancyCheck Created: 15/Dec/23 Updated: 07/Feb/24 Resolved: 07/Feb/24 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 8.0.0-rc0 |
| Type: | Task | Priority: | Major - P3 |
| Reporter: | Didier Nadeau | Assignee: | Dominic Hernandez |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | ntdi_code_quality | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Backwards Compatibility: | Fully Compatible |
| Sprint: | Service Arch 2024-01-08, Service Arch 2024-01-22, Service Arch 2024-02-05, Service Arch 2024-02-19 |
| Participants: | |
| Story Points: | 1 |
| Description |
|
MultitenancyCheck was added as a workaround to skip $tenant checks in the mongo bridge process. This is because the `op_msg.cpp` is shared between various process (such as mongod, mongos, mongo bridge, etc) and contains a tenant-related check relying on `multitenancySupport`. Now that $tenant is being removed `MultitenancyCheck` doesn't really makes sense because we don't use the class to perform checks. Instead we perform an `uassert` on the token if `MultitenancyCheck` exists otherwise we skip the uassert. This produces "correct" logic because the object exists in mongod and mongos but not mongo bridge. However the implementation is not very elegant or clean. |
| Comments |
| Comment by Githook User [ 07/Feb/24 ] |
|
Author: {'name': 'Dominic', 'email': 'dominic.hernandez@mongodb.com', 'username': 'dom-hernandez'}Message: GitOrigin-RevId: 3cf4bf2a0f83f2d1e2530233a9cbe6e51eefb6e6 |