Relevant details:
Our team has a goal of responding to tickets with a "Support Portal Priority" of Highest within 1 hour, however that goal changes to 4 hours if a ticket is received outside of standard calendar hours.
I know it's impossible to use JQL to query the hour of the day a ticket was entered, so I can't filter my SLA using that method.
How can I create a Time to First Response SLA with two separate goals for Highest priority tickets based on the time of day the ticket was entered?
I'm not sure what you want is actually possible using just the SLA goals and splitting the calendar.
I'm thinking of something else perhaps a bit of a workarround.
Let's say you have a "Support Portal Priority" of "High" and this can be created both inside or outside of business hours. For your use case you would want a different goal based on the time of creation.
I'm then thinking of using an additional field (that is hidden to the end user (and maybe even the agent)) which you can set through perhaps the Automation/an automation plugin.
My idea is as follows:
- Create a flag/boolean/custom field called "Created Outside of Business Hours"
If the ticket is created within the business hours this is set to False
If this ticket is created outside of the hours it is set to True
You can then use that additional parameter to create 2 goals.
e.g.
Support Portal Priority = "High" AND "Created Outside of Business Hours" = False Then the goal is 1hr (using a calendar of 9-5)
Support Portal Priority = "High" AND "Created Outside of Business Hours" = True then the goal is 4hrs (using a calendar of 5-9)
If you want the goals to continue to count even outside of the calendar you can just make a 24/7 calendar but based on the custom field value you can set a different goal..
Cause that would only change the goal based on the custom field value (which in return is a reflection of the time of day created)
Thats my 2cents and how I would solve this :)
True :) Thank you for pointing this out.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hey @Greg Hart ,
With an addon like Scriptrunner you could write a small script that compares the now() value (or the issue.created value with a predefined value (like > 9am but <5pm).
i'm checking now whether this is also possible with the built in automation.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I played arround a bit with the timefunctions in Automation and came up with the following: (is this perfect or the only way, no. But will this work, normally yes :))
I created an automation with:
Trigger: Issue Created
Condition: Advanced compare {{now.format("HH")}} greater than 8
(this returns the absolute hour in 24h format) meaning that 8.59 will still be false but 9.00 is true)
and
Condition: Advanced compare {{now.format("HH")}} less than 17 (thats 5PM) so 4.59 is ok, 5pm not
Action: set a field.
I ran this as a manual trigger as a test and it works fine. I did use the 24h format as it's easier to distinguish between 5am and 5pm (5 vs 17) instead of having to find whether it's am or pm (and i use 24h clocks all day so :))
Hope this helps!
of course change this to issue created as a trigger and set the field you want to set in the end.
Based on that you should be able to define your goal then for your SLA
Edit: if you have issues with the time being wrong take a look at timezones.
https://support.atlassian.com/jira-software-cloud/docs/smart-values-date-and-time-functions/
you could replace the {{now.format("HH")}} with {{now.convertToTimeZone(AEDT).format("HH")}} if i'm not mistaken. (and you can find a list of timezone abreviations here
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Dirk Ronsmans This is perfect! Trying to sell The Powers That Be on spending more money on yet another add on was going to be a chore. We've been using this version of automation for a while now, so this works out how I need it to. Thank you!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Be sure to test it first ofcourse cause I'm just throwing this together as we speak :)
But my initial testing seems ok! (i added a small part about timezones should you need it)
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hey @Greg Hart ,
Just to follow up on this @Jack has a nice approach to this one without any automation.
You could indeed use a more complex but refined SLA Goal JQL using the StartOfDay() clause
priority = highest and createddate >= startofday(“+8h”) and createddate < startofday(“+17h”)
This would eliminate the need for the automation all together.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I thought about trying that, but figured since startOfDay() and endOfDay() were always based on the current day, that would cause issues with viewing SLAs in the following days. But now that I think about it, I guess those functions would only be run when the SLA is initially calculated.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Also true..
Initially it might not cause issues but there will be one if you have to recalculate the SLA's..
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Greg Hart
You can enter a separate calendar for out of business hours like this:
Then you need to define separate goals with this new out-of-business-hours calendar with your JQL conditions.
The above screenshot is for sample 9-5 calendar, as you can see I had to split the calendar into two parts. You can adjust the calendar based on your working hours calendar.
You also need to create a boolean cf to separate tickets that created out-of-business hours. Thanks @Dirk Ronsmans :)
Let me know if you have further questions.
Cheers,
Gökçe
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
While I agree you would need to define 2 calendars (one for business hours one for outside) how would this work when having the same condition on the goals?
for example if you have a "Support Portal Priority" of "High" and you link them to both the business and outside of business hours calendars wouldn't they just both be active?
One will then be paused during the time it's not valid and the other one would run.
But this would not be valid against the time of the issue creation imho.
Once you cross over from business to outside or the other way arround this would get very confusing.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.