[DOCS-15885] Investigate changes in SERVER-71678: Allow compact to run on system collections Created: 07/Feb/23  Updated: 13/Nov/23  Resolved: 02/Aug/23

Status: Closed
Project: Documentation
Component/s: manual, Server
Affects Version/s: 7.0.0-rc0
Fix Version/s: 7.0.0-rc0, Server_Docs_20231030, Server_Docs_20231106, Server_Docs_20231105, Server_Docs_20231113

Type: Task Priority: Major - P3
Reporter: Backlog - Core Eng Program Management Team Assignee: Corry Root
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Documented
documents SERVER-71678 Allow compact to run on system collec... Closed
Participants:
Days since reply: 1 year, 1 day ago
Story Points: 2

 Description   
Original Downstream Change Summary

It is now possible to run compact on a system collection.

Interestingly, it appears that the docs for the compact command already incorrectly state this is possible, dating back as far as at least 4.2 ("For system collections...."): https://www.mongodb.com/docs/v4.2/reference/command/compact/#compact-required-privileges

Description of Linked Ticket

System collections can't be compacted:

// Items in system.* cannot be moved as there might be pointers to them.
uassert(ErrorCodes::InvalidNamespace, "can't compact a system namespace", !nss.isSystem());

This restriction was added in SERVER-11595 and is likely an MMAP limitation. With WiredTiger being the default storage engine, this is no longer necessary as WiredTiger supports online compaction.


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