Author Topic: SelectDN and SuspendForDN in loop with a changing skill expression.  (Read 170 times)

Offline sorav84

  • Newbie
  • *
  • Posts: 38
  • Karma: 0
Hi all,

I am facing an issue in routing design, please point me to the thread if this has been discussed already and apologies in advance, where in targeting phase  we are using SelectDN and SuspendforDN in a loop.
The loop is controlled using timestamp before and after and comparing with configured value (user input through parameter group). The logic is like this:

Step 1. Loops begins , target skill expression -->ServiceSkill_A &(SiteSkill_A |SiteSkill_B| SiteSkill_C) using selectDN and peg VQ --> _VQ
Step 2. if timeout happens wait for skill to become available using SuspendForDN[5].
Step 3. if timeout happens perform another check , check all site skills and remove the skill which is not available.(site skill is also user input controlled). Let's say SiteSkill_A is removed.
Step 4. Loop back to Step 1. and use updated skill expression --> ServiceSkill_A & (SiteSkill_B|SiteSkill_C|SiteSkill_D)

Now the issue is SelectDN picks up updated skill expression immediately but SuspendForDN doesn't and other than timeout it doesn't have any other parameter. I could see in the logs that there are two internal queues maintained against two different skill expressions. One with SelectDN and other with SuspendForDN.
Earlier I was using ClearTargets to solve this problem but had to remove because it caused reporting issues and is an uphill task to change/modify all related stats.

Thanks in advance and apologies for long post :)

Offline terry

  • Sr. Member
  • ****
  • Posts: 270
  • Karma: 32
Re: SelectDN and SuspendForDN in loop with a changing skill expression.
« Reply #1 on: April 08, 2019, 12:34:21 PM »
 Dont think you correctly interpret URS log.
SuspendForDN doesn't have it's own queue, only SelectDN has.
SuspendDN check only queues  call was placed in by SelectDN.
If you really make a loop, call simply not able be in 2 queues (if only strategy doesn't execute MultiplyTargets function).

Old queue might continue to exist on it's own (without any connected to it call) but it will not actually work until some call will be placed in it.

Offline sorav84

  • Newbie
  • *
  • Posts: 38
  • Karma: 0
Re: SelectDN and SuspendForDN in loop with a changing skill expression.
« Reply #2 on: April 09, 2019, 01:45:17 PM »
Hi Terry,

Many thanks for the response. Here is what I saw in the logs and observed when call routed to IWS:

1. You are right, SuspendForDN doesn't have it's own queue. Here I don't mean VQ , which is nothing but a representation.
2. Every time SelectDN executes with a different skill expression, if you don't move out of that subroutine or strategy, it creates a hexadecimal number something like
VQ 00000000024fad90 "?:Skill_A=10&Skill_B=10"

3. Now , your VQ as in for reporting will not change, but whenever you change skill expression  SelectDN will change this number as if it is creating an internal queue against every skill expression.
4. After that if you see SuspendForDN execution it will show all those old skill expression including current  with this respective VQ <hex number>. SelectForDN will only show current skill expression.

Unless I put in a ClearTarget function which resets everything SuspendForDN doesn't let go off old expressions.

« Last Edit: April 09, 2019, 01:52:30 PM by sorav84 »

Offline terry

  • Sr. Member
  • ****
  • Posts: 270
  • Karma: 32
Re: SelectDN and SuspendForDN in loop with a changing skill expression.
« Reply #3 on: April 10, 2019, 03:51:56 AM »

1. SelectDN creates VQ and its hexadecimal number - if such queue doesn't already exist.
2. If you try to use SelectDN another time (for the same call or any different call) with exactly the same target - no VQ (queue) will be created  - hexadecimal number of existing queue will be used.
3. Queues (or VQs in URS log) as result are shared between calls objects - many different calls or the same call many times can be in it.
4. You can not change queue itself call is in - it would affect other calls which happen to be in the same queue - you can move call into different queues instead.
5. One SelectDN connect call with one VQ.
   5a. to connect call with (put call into) few VQ  - few different instances of SelectDN should be used in strategy.
   5b. Looping onto the same SelectDN in strategy results that call is removed from old VQ ()connected with call
        by previous execution of this SelectDN and placed into new one.

To remove call from VQ - either you need to enter the sane SelectDN again (call will be entered into new queue and removed from old one) or need explicitly to cancel result of SelectDN with function like ClearTargets ot its variation. 
 

Offline sorav84

  • Newbie
  • *
  • Posts: 38
  • Karma: 0
Re: SelectDN and SuspendForDN in loop with a changing skill expression.
« Reply #4 on: April 12, 2019, 12:35:36 AM »
Well, that's true. I had asked this question on genesys as well but somehow I knew that there won't be any solution. I felt that this is a simple ask, I know SuspendForDN isn't the answer, that if we want to change skill expression , whenever we want, we should be able to without clearing VQ information. Routing should be flexible enough, I hope Composer/ORS may have an answer.

Thank you for your reply, terry.