You're looking for this ScriptRunner module: https://scriptrunner.adaptavist.com/latest/jira/custom-jql-functions.html
I have created JQL functions to search on Projects, Users, and Versions before, but I haven't tried to extract @mentions from comments.
You're likely going to need to use CommentManager.getLastComment(Issue issue) to obtain the last comment for each issue, then you can use Comment.getBody() to obtain the comment text. Finally, you can parse the content to search for the mention format, which is stored like this: [~username]. Once you extract this, you can compare the mentions to the argument passed to the JQL function.
Hey Community mates! Claire here from the Software Product Marketing team. We all know software development changes rapidly, and it's often tough to keep up. But from our research, we've found the h...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG