Ticket first response time reached option generic agent

Moderator: crythias

Locked
chaitanyacda
Znuny newbie
Posts: 33
Joined: 26 Feb 2013, 13:23
Znuny Version: 3.1.4
Real Name: Chaitanya Ambaselkar
Company: InfoCepts

Ticket first response time reached option generic agent

Post by chaitanyacda »

Greetings all,

I am trying to configure a generic agent to move a ticket from one queue to another based on some escalation times. I am unable to understand the options

Code: Select all

Ticket first response time reached
- Last
-Before
What do Last and Before signify? When do I use Last and when do I use before?

And is it possible to ignore those tickets on which generic agent has already been run?
OTRS 3.14 on Cent OS 6 64bit with MySQL
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Ticket first response time reached option generic agent

Post by crythias »

[in the] Last [n] [time units]
Before [n] [time units] [ago]


or:
(beginning of time)-------Before------[n] [timeunits]-----Last-----(Now)
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Ticket first response time reached option generic agent

Post by crythias »

chaitanyacda wrote:And is it possible to ignore those tickets on which generic agent has already been run?
Generally, no, but then again, let's say the criteria checks if the ticket is in Queue A and moves to Queue B if additional criteria has been met.
1) If the Ticket has been moved to Queue B, it is no longer in Queue A, so that won't happen again.
2) If the criteria hadn't been met previously, it's going to check again, as often as the generic agent runs. Since it won't *do* anything until criteria is met, nothing happens..
3) If there is a subsequent generic agent that moves from queue B to queue A based upon criteria, this could create a loop, so one or the other generic agent should check additional criteria (a set state, etc.)
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
chaitanyacda
Znuny newbie
Posts: 33
Joined: 26 Feb 2013, 13:23
Znuny Version: 3.1.4
Real Name: Chaitanya Ambaselkar
Company: InfoCepts

Re: Ticket first response time reached option generic agent

Post by chaitanyacda »

crythias wrote:[in the] Last [n] [time units]
Before [n] [time units] [ago]


or:
(beginning of time)-------Before------[n] [timeunits]-----Last-----(Now)
I think I am still confused. I am still not able to use those thresholds properly to my requirements. If you can help me understand with my use case

Suppose, I have three queues, Level-1, Level-2, Level-3. All the tickets come to Level-1 through email. It has First response SLA of 5 mins. If that is violated, I would like to move it to Level-2.
Level-2 has first response SLA of another 5 mins (total of 10mins from the time ticket was raised). If that is again violated, I would like to move it to Level-3.

I think I am missing something due to which, Level-1 to Level-2 and Level-2 to Level-3 is taking place simultaneously thus moving the ticket directly to Level-3.

Somehow, I am not able to decide if I should use Before option or Last option to check if the time of first response has reached.

If you can help me understand where am I making errors(blunders). I have been struggling with this for two days and still unable to understand why this is happening.
OTRS 3.14 on Cent OS 6 64bit with MySQL
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Ticket first response time reached option generic agent

Post by crythias »

chaitanyacda wrote:Suppose, I have three queues, Level-1, Level-2, Level-3. All the tickets come to Level-1 through email. It has First response SLA of 5 mins.
If Queue = Level-1 and SLA before 5 minutes ago, set Queue = Level-2

chaitanyacda wrote:evel-2 has first response SLA of another 5 mins (total of 10mins from the time ticket was raised)
If Queue = Level-2 and SLA before 10 minutes ago, set Queue = level-3

At least, that's my first blush guess at it.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
chaitanyacda
Znuny newbie
Posts: 33
Joined: 26 Feb 2013, 13:23
Znuny Version: 3.1.4
Real Name: Chaitanya Ambaselkar
Company: InfoCepts

Re: Ticket first response time reached option generic agent

Post by chaitanyacda »

crythias wrote:
chaitanyacda wrote:Suppose, I have three queues, Level-1, Level-2, Level-3. All the tickets come to Level-1 through email. It has First response SLA of 5 mins.
If Queue = Level-1 and SLA before 5 minutes ago, set Queue = Level-2
The systems waiting for 5 mins after the ticket has escalated. So that's not working as I require.

If Queue = Level-2 and SLA before 10 minutes ago, set Queue = level-3

At least, that's my first blush guess at it.
Is there a way to move the ticket as soon as it has escalated?
OTRS 3.14 on Cent OS 6 64bit with MySQL
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Ticket first response time reached option generic agent

Post by crythias »

If you say 5 minutes is 5 minutes after escalation then 1 minute would be one minute after escalation.
Note that Generic agent happens at most every 10 minutes, so there's not a real time check for escalation unless you make one that runs every minute (programming).
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
chaitanyacda
Znuny newbie
Posts: 33
Joined: 26 Feb 2013, 13:23
Znuny Version: 3.1.4
Real Name: Chaitanya Ambaselkar
Company: InfoCepts

Re: Ticket first response time reached option generic agent

Post by chaitanyacda »

I am still unsure what is happening here.

One query:

If a ticket gets escalated from say Level-1 to Level-2. Now there is another job that will move the ticket from Level-2 to Level-3 if escalation has happened. I want to know if the time ticks of the ticket are reset when the ticket is moved to Level-2 or the time the ticket was raised is stamped on ticket and never changes?

Also,

If I want to make this happen

Code: Select all


                                              |-----------20mins----------|
Level-1 ---------20mins-------Level-2-------------------Level-3
|------------------------------40mins---------------------------|
I am not sure how should I handle Level-2 to Level-3 escalation. What should SLA say in Level-2 first response? Should the first response SLA in Level-2 say 20mins or 40mins? And how should I create Generic Agent?
OTRS 3.14 on Cent OS 6 64bit with MySQL
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Ticket first response time reached option generic agent

Post by crythias »

I really don't understand the point of changing Queues anyway. It doesn't make much sense that you should want to change the group of people who can address the ticket simply because an escalation *time* occurs. Chances are, this ticket is still locked and owned by the first person, and if not ever addressed, it should just bug everyone it could possibly bug via email for as long as it remains in escalation state (Notification event?) and email-spam *more* people when greater thresholds are met (meanwhile, states of type open changes or priority increases as escalation exceeds set trigger points, and notification events react to the state change.)

So, you set up escalation notification groups Tiers 1,2,3

and, say ... state is open (this is level-1). If ticket has been in state open and create time before 20 minutes, change state (a new one that you create, of type "open") via Generic Agent to Level-2.
Send a Notification Event on State change from Level-1 to Level-2 ... "Hey, can someone close this ticket?"

If a ticket has been in state Level-2 and create time before 40 minutes, change state (again, new one) via Generic Agent to Level-3.
Send a Notification Event on State Change from Level-2 to Level-3 "Um. See, the ticket hasn't been addressed in 40 minutes. get on it"

It's really not a good idea to create queues for escalation unless you honestly have Tiers of agents who need to handle tickets above the noise of the general queue, and event then, you would usually confer with a manager or the higher Tier agent(s) before manually sending them the ticket (change owner and/or change queue).
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
chaitanyacda
Znuny newbie
Posts: 33
Joined: 26 Feb 2013, 13:23
Znuny Version: 3.1.4
Real Name: Chaitanya Ambaselkar
Company: InfoCepts

Re: Ticket first response time reached option generic agent

Post by chaitanyacda »

Hi,

This is a specific requirement that has come up and I actually cant do much about it. My intention to create multiple queues was to bug people higher in order to check the ticket and respond to it. I am not considering closure time but first response time only. So, if a ticket has remained unanswered in Level-1 for 25mins, then it will escalate to Level-2 and those guys would be sent an SMS.
Further, if a ticket remains in Level-2 for 40mins unanswered, then it escalates to Level-3 and an SMS is sent to Project Manager and Relationship Manager directly. This is being done as we have very strict SLA contracts with customer and we do not want those to be violated. And I can very easily assign different people to different queues.
If you can suggest a mechanism to get this done? If this is possible in the first place? At least escalation warnings should have been sent without any issues, but those are also not been sent.

Code: Select all


|--------10min---------|
Level-1--------Escalation warning-----------Level-2------------------Level-3
|-------------------------25min------------------|
|------------------------------------40min-----------------------------------|

Also for Level-2 to Level-3 escalation, from which time does it start counting for escalation? The time when original ticket was created in Level-1 or from the time ticket was moved to Level-2? This consideration will also definitely affect the way I am trying to judge the escalation.
OTRS 3.14 on Cent OS 6 64bit with MySQL
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Ticket first response time reached option generic agent

Post by crythias »

1) Find a threshold (that includes a value of another field at the current threshold).
2) Change that other field's value
3) Run a notification Event against the value change.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
chaitanyacda
Znuny newbie
Posts: 33
Joined: 26 Feb 2013, 13:23
Znuny Version: 3.1.4
Real Name: Chaitanya Ambaselkar
Company: InfoCepts

Re: Ticket first response time reached option generic agent

Post by chaitanyacda »

crythias wrote:1) Find a threshold (that includes a value of another field at the current threshold).
2) Change that other field's value
3) Run a notification Event against the value change.
I am a real newbie to OTRS. I dont understand what do you want me to do. As far as thresholds are concerned, I know the value in minutes.

1. If ticket is in Level-1, unanswered for 10mins, generate escalation warning. If it is still in Level-1 for 25mins, escalate to Level-2
2. If ticket is in Level-2 for 40mins since ticket was generated, escalate it to Level-3

If you want I can give you my configuration, but I am sure its incorrect as its not working as expected.
OTRS 3.14 on Cent OS 6 64bit with MySQL
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Ticket first response time reached option generic agent

Post by crythias »

note that a ticket that is owned and locked will not let others in a new queue know that it's in the new queue, so the efficacy of changing the queue for notification purposes is diminished.
chaitanyacda wrote: If ticket is in Level-1, unanswered for 10mins, generate escalation warning.
Escalation notifications already occurs/should occur, and you should know how to do this. Or there are posts on this board regarding escalation emails.
chaitanyacda wrote:If it is still in Level-1 for 25mins, escalate to Level-2
This has been answered already. You say " I am not considering closure time but first response time only. "
chaitanyacda wrote:If ticket is in Level-2 for 40mins since ticket was generated, escalate it to Level-3
This has already been answered, as has been answered your original question.
(just change the word "state" to "queue")
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
chaitanyacda
Znuny newbie
Posts: 33
Joined: 26 Feb 2013, 13:23
Znuny Version: 3.1.4
Real Name: Chaitanya Ambaselkar
Company: InfoCepts

Re: Ticket first response time reached option generic agent

Post by chaitanyacda »

crythias wrote:note that a ticket that is owned and locked will not let others in a new queue know that it's in the new queue, so the efficacy of changing the queue for notification purposes is diminished.
chaitanyacda wrote: If ticket is in Level-1, unanswered for 10mins, generate escalation warning.
Escalation notifications already occurs/should occur, and you should know how to do this. Or there are posts on this board regarding escalation emails.
chaitanyacda wrote:If it is still in Level-1 for 25mins, escalate to Level-2
This has been answered already. You say " I am not considering closure time but first response time only. "
chaitanyacda wrote:If ticket is in Level-2 for 40mins since ticket was generated, escalate it to Level-3
This has already been answered, as has been answered your original question.
(just change the word "state" to "queue")
Okay. I have made a change. Please let me know if you think what I did was correct or my assumptions are correct:

1. I am only concerned about first response. So if there is no first response, the ticket state is "New".
- If ticket state is NEW, in Level-1, create time before 25mins, move it to Level-2
- If ticket state is NEW, in Level-2, create time before 40mins, move it to Level-3
2. As for escalation warnings, I have already edited the GenericAgent.pm as described in the forums, but still emails are not being sent. Can you help me debug the issue? All the other emails are being sent, hence I know SMTP settings are good and working.

Thanks for all the help you have been providing. Appreciate it a lot.
OTRS 3.14 on Cent OS 6 64bit with MySQL
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Ticket first response time reached option generic agent

Post by crythias »

chaitanyacda wrote:I have already edited the GenericAgent.pm as described in the forums,
Also the var/cron/generic_agent.dist needs to be var/cron/generic_agent and possibly edited for more frequent than every */20 minutes.
and restart otrs cron service (read the INSTALL.md for more information)

After this, System Log messages whether triggers are reached and emails are sent or not.

Edit, yes, your last post sounds reasonably close to what you wish to accomplish. I still want to remind you that someone can lock a ticket and it will still be new and the move into queue notifications will not send to the agents of the new queue.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
chaitanyacda
Znuny newbie
Posts: 33
Joined: 26 Feb 2013, 13:23
Znuny Version: 3.1.4
Real Name: Chaitanya Ambaselkar
Company: InfoCepts

Re: Ticket first response time reached option generic agent

Post by chaitanyacda »

crythias wrote:
chaitanyacda wrote:I have already edited the GenericAgent.pm as described in the forums,
Also the var/cron/generic_agent.dist needs to be var/cron/generic_agent and possibly edited for more frequent than every */20 minutes.
and restart otrs cron service (read the INSTALL.md for more information)

After this, System Log messages whether triggers are reached and emails are sent or not.

Edit, yes, your last post sounds reasonably close to what you wish to accomplish. I still want to remind you that someone can lock a ticket and it will still be new and the move into queue notifications will not send to the agents of the new queue.
I think generic agent jobs are also running properly as tickets are being fetched from the inbox. I guess there is something else I may be missing.
For the last issue, I think agents would not keep it locked without putting the first reply as that would create escalations which are to be avoided at any cost. But I do not understand, why, if a ticket is locked by an agent and still in new state, is moved to new queue, a notification wont be sent out? Is this by default systems behavior? Can I change this somehow?
OTRS 3.14 on Cent OS 6 64bit with MySQL
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Ticket first response time reached option generic agent

Post by crythias »

chaitanyacda wrote: But I do not understand, why, if a ticket is locked by an agent and still in new state, is moved to new queue, a notification wont be sent out? Is this by default systems behavior? Can I change this somehow?
A locked ticket indicates that someone has control of the ticket. It's not relevant (generally) to anyone else if the ticket changes hats (queues) if the ticket is locked.

Can you change this behavior? Yes, and that question was already answered in this thread (Notification Events).
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
chaitanyacda
Znuny newbie
Posts: 33
Joined: 26 Feb 2013, 13:23
Znuny Version: 3.1.4
Real Name: Chaitanya Ambaselkar
Company: InfoCepts

Re: Ticket first response time reached option generic agent

Post by chaitanyacda »

crythias wrote:
chaitanyacda wrote: But I do not understand, why, if a ticket is locked by an agent and still in new state, is moved to new queue, a notification wont be sent out? Is this by default systems behavior? Can I change this somehow?
A locked ticket indicates that someone has control of the ticket. It's not relevant (generally) to anyone else if the ticket changes hats (queues) if the ticket is locked.

Can you change this behavior? Yes, and that question was already answered in this thread (Notification Events).
Also, I think I can create a generic agent to unlock a ticket if the ticket has been locked and still in NEW state for say 10mins. Is this reasonably okay? How would running lot of generic agent jobs affect the system performance?

Else, I will try to use Notification Events as well. One question though, Can I use multiple email addresses (Not distribution lists) in one Notification Event? Something like separated by comma or a semi-colon? Does this work?
OTRS 3.14 on Cent OS 6 64bit with MySQL
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Ticket first response time reached option generic agent

Post by crythias »

chaitanyacda wrote:Also, I think I can create a generic agent to unlock a ticket if the ticket has been locked and still in NEW state for say 10mins. Is this reasonably okay?
Queues have lock timeout parameters (default 0/never) (this is run hourly by cron, though... var/cron/unlock[.dist] at 35 minutes after the hour. you might choose */5 minutes if necessary)
Check SysConfig
Ticket::EventModulePost###910-ForceUnlockOnMove to unlock on move/change queue. (Or, of course, unlock at generic agent). Make sure the notifications enabled is checked in the Generic Agent.
chaitanyacda wrote:How would running lot of generic agent jobs affect the system performance?
Depends what they do, how often they run, how many tickets are affected, how many jobs are considered "a lot" ... if you see a performance hit somewhere, you'll have to determine the cause. This is not something I can determine in a crystal ball fashion for your scenario.
chaitanyacda wrote:Can I use multiple email addresses (Not distribution lists) in one Notification Event? Something like separated by comma or a semi-colon? Does this work?
If you have tried it, you would be asking a different question. (No, it probably does not, but then I didn't get it to work on 3.2 ... haven't tried it in 3.3)
Note that OTRS group membership counts as a multiple-email recipient group.

I realize this has been easier for you to have a dialog for all variations of your original topic within this topic, but it could be easier for people who visit this forum to research different segments of your questions in different forum topics.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
chaitanyacda
Znuny newbie
Posts: 33
Joined: 26 Feb 2013, 13:23
Znuny Version: 3.1.4
Real Name: Chaitanya Ambaselkar
Company: InfoCepts

Re: Ticket first response time reached option generic agent

Post by chaitanyacda »

Hi,

Thanks for your responses. Currently I would like to mark this thread as solved as I think you have answered most of my very important questions those were sort of road blockers for us in this particular implementation. Thanks for your time and effort in helping me.
OTRS 3.14 on Cent OS 6 64bit with MySQL
Locked