- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
4 weeks ago
We are using ServiceNow as an Intake form for Azure DevOps (AzDo) requests. A person submits a request on the Service Portal, an Epic is created, and then immediately sent over to AzDo. Real-time synch is set between ServiceNow and AzDo, so if one is updated, it sends the updates to the other.
The trigger for ServiceNow sending the initial Epic over to AzDo is the population of the Assignment Group field, which is handled/set by a Template on the Record Producer. There is a Business Rule named "Synch Epic with Azure DevOps" (which I believe came with the Azure Spoke) which handles the sending the record over to AzDo. The Business Rule looks like this:
This works well for most of our Record Producers. However, we have 2 which behave a little differently. They want the Record Producers to go through an Approval BEFORE being sent over to AzDo. So for those two, we do NOT have the Template on the Record Producer populating the Assignment Group field. Instead, we have a Flow that creates the Approval, and if Approved, it then populates the Assignment Group field, which in turn triggers the record to go over to AzDo.
So we made a copy of the initial Business Rule to handle those cases and it looks like this:
And it works, in that it waits until the Assignment Group field is populated before sending these Epic records over to AzDo.
However, we are encountering an unexpected issue. For these records (and these records only), if a Comment is made on the AzDo record, it correctly sends it over to ServiceNow, where the Epic record there is updated with that Comment. However, then ServiceNow re-sends that comment it just received from AzDo back to AzDo, so now the Comments appears twice in AzDo, and we are not sure why.
We tried messing with our second Business Rule, trying various combinations of Insert/Update, Before/After, and changing the condition "Approval is Approved" to "Approval Changes to Approved", but none of the combinations worked properly. Either it would not send anything over to AzDo at all, or we would still have this duplication issue if a Comment was made on the AzDo side.
Can anyone spot the flaw in the logic, or have any recommendations on how to adjust our Business Rule so that it does not send the Comments it receives from AzDo back to AzDo?
Thanks
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
What happens if you just use the record producer condition and the assignment group one and leave out the approval completely (as you mentioned: it happens at the same time, so no need for both).
Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
I tried changing it to a "Before" Business Rule, and changed the last two criteria to:
"Approval changes to Approved"
and
"Assignment Group changes"
like this:
and submitted a new test. I completed the Approval, and nothing happened. It did not send it over to AzDo at all. So that did not work.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
What happens if you just use the record producer condition and the assignment group one and leave out the approval completely (as you mentioned: it happens at the same time, so no need for both).
Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
I am not sure why that worked, but it did.
Thank you very much!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
I think that it only seemed to be working at the same time, but that it was still 2 updates to the system, triggering the rule twice.
Please mark any helpful or correct solutions as such. That helps others find their solutions.
Mark