I'm trying to build a rule in our space that will a) archive pages that have been inactive for over a year and b) notify the page owner that their pages have been archived. I started with the "archive inactive pages" and "notify owners of inactive pages" templates and have been modifying and testing it, but I'm running into some problems I don't know how to resolve.
Some factors I'm working with:
- I need to be able to exclude (or include) sections of spaces where content shouldn't be archived.
- The email notification is necessary because the auto-notification Confluence sends doesn't provide any context and, knowing my users, a nonzero percentage of them will freak out when they get it. So I need to be able to send a custom message on archival.
- Purchasing additional modules isn't a viable option right now.
Currently the flow looks like this:
Problem 1: The flow is wrong.
Here's how I would want the flow to work:
1. Identify inactive pages.
2. Apply exclusions or inclusions, if they're present.
3. Archive pages that fit the criteria.
4. Send the owner of those pages an email informing them of the archival.
Here's how the flow actually works:
1. Identify inactive pages.
2. Apply exclusions or inclusions.
3. Archive pages that fit the criteria.
4. Send the owner of the pages identified in step #1 an email informing them all pages have been archived, regardless of exclusions/inclusions and if those pages were actually archived or not.
How do I get that second branch to pull the "pages archived in step 3" value, rather than the value in step 1?
Problem 2: The "If" condition isn't working.
This one is set up very simply so I don't know how it's going wrong. It should be comparing the parent page of each inactive page to the specified ID and seeing if there's a match. I know it should be pulling up results, based on what I've configured. However, every time I run it, I get the "Unable to render smart values when executing this rule: Failed to get value for page.parent.id" error and it doesn't identify any pages at all.
I had this rule working correctly in my personal space, but when I duplicated it into a communal space, now it doesn't work, and I have no indication of what's causing the error.
I'm hoping someone can give me some insight here - I've reached the limits of what little documentation I can find. Thanks!
Although I have not specifically tried your scenario, I wonder if both of those steps can be done in one rule...
Reviewing the original article when those smart values and rule templates were added, it seems one may perform the page archive or the batched-notification, but not both together. You may need to try this in a test site with a smaller sample size to confirm this, or check with the Atlassian Support team.
There is not a lot of documentation for this Confluence automation feature where the first "branch" looks like a branch, but sometimes it is not one as it merely feeds to populate the owner and author smart values for batch notifications.
For the condition you are checking, I wonder if that page data is present in order to perform the test. You could validate that with a test rule, again based on the template:
Then run the rule from the editor and check the log for the values.
Kind regards,
Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.