Can JEMH be restricted to use just one project

Jo-Anne MacLeod
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 29, 2013

I have a project called SUP (Support). I've configured JEMH to create/update issues in that project. And that portion works fine.

I have a second project, lets called TEST (My Test Project). This is a standard project and is not used by JEMH at all. Completely separate.

When email is sent to dev-support@x.com, the ticket is created in SUP, as it should.

When an email is sent to dev-support@x.com, and the subject contains something like "This is broken in TEST-200". JEMH then processes it and adds a comment on issue, TEST-200. As it is supposed to.

The problem is, regardless of what the subject line contains, I want the issue to be created in SUP (or the comment added to SUP - as appropriate).

I've added a Mapped project in the Configuration section of my profile.
I'v added a email domain mapping, for dev-support@x.com, and set the "Match again the addressee" flag.

The problem is that the comments are getting added to the other project.

Is there a way to restrict my JEMH profile so that ONLY the SUP project is being used. Regardless of what is in the subject line or anywhere else in the body of the email.

1 answer

1 accepted

1 vote
Answer accepted
Andy Brook [Plugin People]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 30, 2013

Theory goes thats easy enough, there is an Email > PreProcessing > Subject IssueKey (comment) Regexps field that can be defined as:

SUP-[0-9]*

This would then only map replies matching SUP-123 format rather than TEST-100?

Jo-Anne MacLeod
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 30, 2013

Thats not quite what I want though. Still want the email that has the "TEST-100" in the subject line to get created in the SUP project as a new issue. Basically if the subjet line does not contain a valid "SUP-123" key, then create a new issue.

Although I may be able to work with what you have provided here though.

Andy Brook [Plugin People]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 30, 2013

I see your variance and raise you a capture group:

(SUP-[0-9]*|[A-Z]*-[0-9]*)

This will then match on the first part matching SUP-123 if present, and if not, the second, which is any ABC-123. This means SUP references take priority for commenting purposes, which is what you want?

Jo-Anne MacLeod
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 30, 2013
Fold! You win. :) I think that is exactly what I needed. Thanks
Andy Brook [Plugin People]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 30, 2013

pls tick answer as correct if this workes for you?

Andy Brook [Plugin People]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 30, 2013

Actually, sorry, the capture group above would then match only the 'first' match, probably not what is intended, to fix this, Ive CSV enabled the field, allowing order to be defined so...

SUP-[0-9]*,[A-Z]*-[0-9]*

... will then achieve what you want as each regexp will be tested indivudally. This will go into JIRA 6.1 compatible 1.5.8, and backported into 5.2.3+, 6.0.x builds also

Andy Brook [Plugin People]
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 31, 2013

available in 1.3.61, 1.4.39 and soon 1.5.8

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events