I had a requirement to configure a mechanism within Office 365 to allow pages on an intranet to expire after a set amount of time. When a page has expired the content owner is alerted and a task is assigned to review the page content.
A number of content types have been designed and each content type can have an information management policy assigned to indicate the retention period.
To configure retention in Office 365:
- Create a content type the usual way
- Connect to the site using SharePoint Designer and create a workflow. Select the SharePoint 2010 workflow engine as this will allow you to connect the workflow to a content type.
- Modify the content type through SharePoint (Site Settings –> Content Types) and select ‘Workflow Settings’
- This should allow you to select the workflow created in step 2.
Now the content type is ready, and the workflow is assigned to the content type – we now need to configure the retention policy:
- Select ‘Information Management Policies Settings’ from the content type page
- Configure a retention policy
- Configure the expiration policy
- Configure the action to start a workflow and select the workflow created earlier.
Note: After testing in Office 365, we cannot manually start the retention timer job to iterate through the expired items – the timer job runs every Sunday at around 08:30 (in my tenant at least) – makes testing quite difficult, so any testing should be completed in an on-prem environment so the timer job can be manually executed.