Using Get-MailboxFolderStatistics To Prove Compliance Records Go Away
Some folks raised the point in discussions in the Microsoft Technical Community that there’s no way to know whether a Teams retention policy is working. As you probably know, a retention policy is an automated background process designed to remove items from Teams after a retention period elapses.
This Petri.com article explains that Office 365 generates no reports to help administrators know if their carefully-crafted retention policy is effective, so if you want to know whether items are being removed, you have to check the group mailbox for a team under the control of the policy to see if the Exchange Online Managed Folder Assistant has processed the mailbox and removed some items. Running the Get-MailboxFolderStatistics cmdlet against the folder in the group mailbox where Teams compliance records are stored is key to knowing that items are being removed.
Things get even more complicated because a further synchronization process must occur to replicate any deletions made by the Managed Folder Assistant back to the Azure-based Teams data services, followed by replication down to Teams clients to make the deleted items disappear from user view. The process works, but it can take up to a full week, depending on the load on the Office 365 infrastructure.
For more information about Teams, see Chapter 13 of Office 365 for IT Pros. And then be sure to read up about Office 365 retention policies in Chapter 19.