(I'm Francis - product manager for Exalate - an issue synchronisation solution)
Challenge
Last week, we got following request -
Hi Francis,
We are using a competing issue synchronisation solution. One of the problems we encounter is that whenever we synchronise a comment, the mentions in that comment are also synchronised - triggering confusing notifications - especially when there are overlapping user id's
Ie. For instance you have @peter in the comment. The comment gets synchronised to the other instance, which triggers a 'You have been mentioned' notification to a complete different Peter (who happens to have the same userid)
How would Exalate deal with it.
Challenge accepted!
Ideally, all the mentions in comments sent to the other side are replaced with the name of the person mentioned. So what should happen
Whenever composing the outgoing synchronization message (aka the data filter)
- For every comment
- For every mention in the comment
- Look up the user being mentioned
- Replace the mention with the name of the mentioned person
With the groovy based scripting engine, it is pretty straightforward to have it done

- Line 18 - iterate over all the issue comments
- Line 21 - RegEx which collects all the mentions in the comment body
A mention is stored as [~<userid>] - Line 24 - Iterate over all the mentions found in the body
- Line 25 - Look up the mentioned user object using the nodeHelper.getUser
- If the user is found, set target to display name
- if the user is not found, set target to the userid of the user
- Line 26 - Replace all the mentions for this specific user to the constructed target
- Line 29 - Assign the new comment body to the comment
(The code snippet above can be found here)
What is the effect
Now whenever someone creates a comment on the source like following message

The piece of groovy code will replace the mentions of Peter and Angie with their Full Name, and send this over to the other side, resulting in

Other use cases
This is just an example of what the flexibility provided by Exalate allows to do.
You can imagine that you want to filter out the names of the people (for security or GDPR reasons) or map the mentioned users from the source user to the target user.
Many more use cases can be implemented. We are looking forward to solving your synchronization challenges. Welcome to book a meeting here