In previous posts, I discussed creating retention labels and publishing them to your various sites. This is an effective way to ensure record retention processes are followed within your organization. However, the process can require a lot of user interaction. Many organizations find their users do not apply labels. The reasons for this range from being unsure which option to select to not having time to do it. This can cause records to be deleted before they should or kept longer than required. In this post, we’ll help to alleviate that by using an auto-apply retention label policy. It’s a bit of a longer post, but there can be many parts to properly configuring auto-apply retention labels.
Disclaimer: Microsoft is making changes all the time to the Microsoft 365 interface. Any screenshots displayed in this post are current at the last edit of the post.
Auto-Apply Retention Label Policy
An Auto-apply retention label policy is exactly as it sounds. They will apply retention labels to content based on several different methods. This removes the need for user interaction when labels need to be applied.
Note: Auto-application of retention labels is not supported with E3 licenses. Either an E5 Compliance Add-on is required for the E3, or a full E5 license is necessary to remain compliant with Microsoft licensing.
The methods for assigning retention labels include:
-
- based on sensitive information within the content
- specific words or phrases within the content, metadata, etc. This requires the use of Keyword Query Language (KQL)
- trainable classifiers (we’ll cover this in another post).
The most common configuration uses the second option, and this will be demonstrated in today’s post. I’ll cover the others in a future post.
Create a Content Type in the Tenant Content Type Gallery
For the tenant to utilize the site column you are using in your SharePoint site, it must be created in the content type gallery (formally known as the content type hub). This is located within the SharePoint Administration Console. Previous testing found that any site collection-based site columns did not work with auto-apply policies. This may be repaired in the future, but the tenant-level site column was required at the last update to this blog post.
- Login to the SharePoint Admin console with the necessary credentials.
- Click on “Content Services” and click “Content type gallery.”
- Click “+Create content type”.
- Provide the content type with a meaningful name, description, category, and parent content type.
- Once the content type is created, click on it to configure the settings.
- Click on “+ Add site column” to create the necessary site columns for the auto-apply label (you will have the option to create a new one or utilize an existing site column).
- Create the site column to meet the needs of the record management team. A suggestion is to use a choice column or a managed metadata column to ensure options are available for users and spelling is always correct.
- Add any other site columns required.
- Once complete, review the content type and click publish if the configuration is done (note, the content type can be updated later if necessary).
- Publishing content types is relatively quick but allows the tenant time to push it out to the updated sites.
- Once updated, the content type can be utilized in libraries, or the site column created can be added to existing content types within the site collection.
Add the Site Column to a Managed Property
Once the site column has been created, it needs to be added to a managed property. When a new site column is added to a library, it will have a crawled property added to the search schema. This crawled property must be linked to a managed property to be searchable by the auto-apply policy. To update the schema:
- Login to the SharePoint administration console with the necessary credentials.
- Click on More features and then Open in the Search section.
- Click on “Manage Search Schema”
- Click on Crawled Properties, search for the site column’s internal name, and click the search arrow.
Note: in the example above, three properties are returned. This example uses a managed metadata field. This field creates three internal properties. Ensure the ows_<Internal Site Column Name> is selected.
- Select the correct property. If in doubt, the field beginning with ows_ is the property to select.
- Click on Add a mapping, search for an existing managed property such as RefinableString30 and click OK. Click OK again to exit the crawled property configuration page.
Important: The RefinableString property cannot exceed RefinableString99. There is a bug that auto-apply policies, labels, events, and content searches cannot search any managed property from RefinableString100 to RefinableString199. It does work within other search tools, but the back-end searches will not work.
- Once the managed and crawled property are linked, allow 24 hours for all the back-end processes to refresh before creating the auto-apply retention.
Test Query with Content Search
To ensure the query to be used for the auto-apply retention label policy is correct, first, utilize the Content Search functionality of the Compliance Console within Microsoft 365. The content search will run the same process within its search as the policy will. For this, do not trust in the SharePoint/Microsoft Search on sites. More search functionalities have been added to aid users, and false positives when testing is common.
- Navigate to the Records Management section of the M365 Compliance Console (https://compliance.microsoft.com/recordsmanagement)
- Click on Content Search and then “+ New search.”
- Provide the search with a meaningful name and a description.
- Click Next.
- On the next screen, select the location(s) that the query should run against. In this case, choose SharePoint.
- Every SharePoint site can be scanned, but to save time, and since this is a test for a specific use case, it is recommended to click on “Choose sites” to point the query at the site used for testing/implementing the policy.
- Enter the site(s) that the query should scan. Click Next.
- Next, add the query to be used in the auto-apply. The format for a managed property base search is <property>:”<value>”. An example is RefinableString30:”Internal Meetings”
- Click Next.
- Review the search criteria, and if everything looks properly configured, click Submit.
- Once the query is complete, review the outcomes. If the results are not as expected, review the query, update, and iterate as required. Once the query returns the desired results, it can be utilized in the auto-apply retention label policy
Creating an Auto-Apply Retention Label Policy Using Keyword Query Language
To create the auto-apply label, perform the following steps:
- Navigate to the Records Management section of the M365 Compliance Console (https://compliance.microsoft.com/recordsmanagement)
- Click on Label Policies.
- Click on Auto-apply a label
- Provide the policy with a meaningful name and description (optional).
- Click Next.
- Select the option: “Apply label to content that contains specific words or phrases, or properties” and click Next.
- Enter the query that was refined in the previous section and click Next.
- Select the locations the policy should be enabled for. Since this example utilizes a SharePoint site column, only SharePoint sites and Microsoft 365 Groups may be selected. The other options can be chosen, but the policy will not work in those locations based on the utilized query.
Important Note: for SharePoint sites that have a Microsoft 365 Group attached, the Microsoft 365 Group must be utilized as well. If only the SharePoint site is selected, content within the SharePoint site will not be updated by the policy.
- All locations can be selected, or a select number can be refined (up to 100 sites, groups, etc.).
- Click Next.
- Click on “+ Add label” to select the label that the policy should apply.
-
- Note: Only a single label can be applied per policy. Notice that “+ Add label” becomes “+ Replace label” after a label is selected.
- Review the settings. Once confirmed, click Submit.
Final Thoughts
Creating an auto-apply retention label policy takes several steps and some serious planning. An auto-apply retention policy utilizes multiple facets of your environment, including SharePoint Online, Microsoft Search, and Microsoft 365 Compliance Center. But in the end, an organization can have a much better user experience when applying information records management processes within their Microsoft 365 tenant.
Thanks for reading!
Comments