Genesys Discussion Forum



Go Back   Genesys Discussion Forum > Developer Discussions > Platform SDK

Platform SDK Integrate directly with underlying servers in your Genesys environment

Reply
 
Thread Tools Display Modes
  #1  
Old 01-06-2011, 05:27 PM
Tem2009 Tem2009 is offline
Member
Newbie
 
Join Date: May 2009
Posts: 14
Tem2009 is an unknown quantity at this point
Default Query on Virtual Queue

Hi -


Is there a way to get the details (e.g. Conn Id) of the calls currently present in Virtual Queue by querying it from T-Server ( or Stat Server)?

e.g. Perform a query on "Test_VQ" DN. I get connIds in return for the calls currently waiting in the queue before they are diverted/distributed.


Thanks in advance for any help.

A.
Reply With Quote
  #2  
Old 01-07-2011, 10:58 AM
vladb vladb is offline
Super Moderator
Power Poster
 
Join Date: Dec 2009
Posts: 358
vladb is a Forum Championvladb is a Forum Champion
Default

Have you tried RequestQueryAddress with AddressType Queue? I think this may provide the information you're looking for.
__________________
Vlad Baranovsky
Program Manager, SDKs
Reply With Quote
  #3  
Old 01-12-2011, 12:03 AM
TimW TimW is offline
Member
Newbie
 
Join Date: May 2009
Posts: 17
TimW is an unknown quantity at this point
Default

Sorry to jump in on this thread but I am trying to achieve the same thing and hitting some issues. I tried with the RequestQueryAddress but this causes the following error we are using Avaya CM T-Server v.8.0.101.05.

Code:
message RequestQueryAddress
	AttributeReferenceID	1
	AttributeThisDN	'VQ_TEST_CONTROL'
	AttributeAddressType	3 (Queue)
@18:37:09.1620 [0] 8.0.101.05 send_to_client: message EventError
	(Invalid attribute)
	AttributeEventSequenceNumber	000000000000b83a
	AttributeTimeinuSecs	162000
	AttributeTimeinSecs	1294771029 (18:37:09)
	AttributeErrorMessage	'ThisDN is virtual'
	AttributeErrorCode	53
	AttributeThisDN	'VQ_TEST_CONTROL'
	AttributeReferenceID	1
So I thought I would check how stat server determines if calls are in queue when it starts up and it seems to use the event EventReserved_2, as it looks like it only shows calls currently queueing after it recieves this event not as it registers the VQ.

I tried to map this event to my C# application but it's not showing as a valid event using the following code / includes.

Code:
using Genesyslab.Platform.Voice.Protocols.TServer.Events;
using Genesyslab.Platform.Voice.Protocols.TServer.Requests.Dn;
using Genesyslab.Platform.Voice.Protocols.TServer.Requests.Queries;
using Genesyslab.Platform.Voice.Protocols.TServer;

mEventBroker.Register(OnEventReserved_2, new MessageIdFilter(EventReserved_2.MessageId));
I even tried just reacting to any event on that VQ and whilst the event is sent to my client (shown in the TServer logs) the following code is not triggered by the EventReserved_2 event but works pefectly with the EventAbandoned when I clear the call down.

Code:
@08:58:00.2570 [0] 8.0.101.05 distribute_user_event: message EventReserved_2
	AttributeEventSequenceNumber	000000000000b9b3
	AttributeCallUUID	'FOPEQ9V1O10CNDIT2NQUVJP0TS000P7S'
	AttributeTimeout	60
	AttributeTimeinSecs	1294822620 (08:57:00)
	AttributeExtensions	[94] 00 03 00 00..
		'SIGNATURE'	'router'
		'VERSION'	'Version: 7.6.100.05'
		'VQID'	'98E1CUHLV147T3U0SBQLA32RQG00000L'
	AttributeThisQueue	'VQ_TEST_CONTROL'
	AttributeThisDN	'VQ_TEST_CONTROL'
	AttributeCallID	12803
	AttributeConnID	008d01de3f4dfb9e
	AttributeCustomerID	'Resources'
	AttributeReferenceID	4294967295
	AttributeUserEvent	EventReserved_2
08:58:00.257 Trc 04542 EventReserved_2 sent to [560] (0000004e TServertestclient)
Code:
mEventBroker.Register(this.EventHandle);

        private void EventHandle(IMessage msg)
        {
            Console.WriteLine(msg.ToString());            
        }
Is there something obvious I am missing to get my app to collect this information?

Thanks for any help you can offer.

Tim
Reply With Quote
  #4  
Old 01-14-2011, 03:09 PM
vladb vladb is offline
Super Moderator
Power Poster
 
Join Date: Dec 2009
Posts: 358
vladb is a Forum Championvladb is a Forum Champion
Default

Looking at this again, I think you may not be able to get this information about a virtual queue. The events you're seeing are undocumented, internal events that aren't available through the SDK.

The better approach is to get this through stat server. Unfortunately, I don't have an environment where I can test this right now, but try something like the below:

Define statistic "CurrentVQState" in the config for StatServer as follows:

Category: CurrentState
MainMask: *
Objects: Queue
Subject: DNStatus

Then:

Code:
RequestOpenStatistic requestOpenStatistic =
    RequestOpenStatistic.Create();

requestOpenStatistic.StatisticObject = StatisticObject.Create();
requestOpenStatistic.StatisticObject.ObjectId = "MyVQ@MySwitch";
requestOpenStatistic.StatisticObject.ObjectType = StatisticObjectType.Queue;
requestOpenStatistic.StatisticObject.TenantName = "MyTenant";
requestOpenStatistic.StatisticObject.TenantPassword = "";
requestOpenStatistic.ReferenceId = 344;
requestOpenStatistic.StatisticMetric = StatisticMetric.Create();
requestOpenStatistic.StatisticMetric.StatisticType = "CurrentVQState";

requestOpenStatistic.Notification = 
    Notification.Create(NotificationMode.Periodical, 30, 0);

IMessage msg = pm["stat"].Request(requestOpenStatistic);
Let me know if this works for you...
__________________
Vlad Baranovsky
Program Manager, SDKs
Reply With Quote
  #5  
Old 01-15-2011, 04:19 AM
Tem2009 Tem2009 is offline
Member
Newbie
 
Join Date: May 2009
Posts: 14
Tem2009 is an unknown quantity at this point
Default

Hi -

When I encountered this error by myself, another post from this forum came to my mind.

With little effort I found this - https://forums.genesyslab.com/showthread.php?p=2416.

While the post does not say if it is possible to get the details from later T-Server(s), it does indicate something like this was possible in 7.2!

Thanks Vlad, will try the stat server approach as well.

A.
Reply With Quote
  #6  
Old 01-18-2011, 07:05 AM
TimW TimW is offline
Member
Newbie
 
Join Date: May 2009
Posts: 17
TimW is an unknown quantity at this point
Default

Thanks for the reply vladb,

Can stat server return an array / list of connids as part of the response?

I set up the request as described but I don't see anything in the message packet from stat server which would provide me with the list of the connids of the calls queueing?

This is the response I get from stat server.

Code:
15:51:12 'EventStatisticOpened' ('22')
message attributes:
REQ_ID [int]    = 344
USER_REQ_ID [int] = -1
TM_SERVER [int] = 1295365703
TM_LENGTH [int] = 0
LONG_VALUE [int] = 0
and

Code:
16:29:04 SS on 'EventInfo' ('2')
message attributes:
REQ_ID [int]    = 344
USER_REQ_ID [int] = -1
TM_SERVER [int] = 1295368144
TM_LENGTH [int] = 0
LONG_VALUE [int] = 5
VOID_VALUE [object] = DnStatus {
	ObjectType = Queue
	DN Id = VQ_TEST_CONTROL
	SwitchId = Avaya
	GSW DN TYPES = 5
	DN Status = 1
	Time = 1295268002
	RealDn = VQ_TEST_CONTROL
}
Thanks again,
Tim

Last edited by TimW; 01-18-2011 at 07:30 AM.
Reply With Quote
  #7  
Old 01-19-2011, 08:18 AM
vladb vladb is offline
Super Moderator
Power Poster
 
Join Date: Dec 2009
Posts: 358
vladb is a Forum Championvladb is a Forum Champion
Default

Hmm.. Alright, let me talk to the dev teams involved and see if there's a recommended way of doing this.
__________________
Vlad Baranovsky
Program Manager, SDKs
Reply With Quote
  #8  
Old 01-19-2011, 11:36 AM
vladb vladb is offline
Super Moderator
Power Poster
 
Join Date: Dec 2009
Posts: 358
vladb is a Forum Championvladb is a Forum Champion
Default

Okay, so I think I may have lied to you guys -- but only because the answer is a bit surprising. :/

It turns out you definitely can't do it with StatServer. With TServer, it sounds like it doesn't actually keep track of the calls as they are simulated via user events. What you may be able to do is listen for "EventCallInfoChanged" notifications on the VQ which will let you track calls being created/changed. It doesn't look like there's a way to do a query, however. If you need more info on this subject, you can try contacting tech support. A TServer expert may offer a better approach to solving this problem.
__________________
Vlad Baranovsky
Program Manager, SDKs
Reply With Quote
  #9  
Old 01-19-2011, 11:07 PM
TimW TimW is offline
Member
Newbie
 
Join Date: May 2009
Posts: 17
TimW is an unknown quantity at this point
Default

Thanks for the information

That is a shame!

Is there no way to open the EventReserved_2 events up to the SDK? Then we could use the same technique as stat server to gain information on calls in queue after a short delay.

Tim
Reply With Quote
  #10  
Old 01-20-2011, 06:35 AM
mjparme mjparme is offline
Senior Member
Power Poster
 
Join Date: Dec 2009
Posts: 121
mjparme is an unknown quantity at this point
Default

You could also just listen for EventQueued from TServer and keep your own model of the calls still waiting to be answered, keyed by connId. It has left the queue when you get EventDiverted.

Remove the call from your model when you get EventDnReleased (has the connId that was on the DN).
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
What is Virtual Queue mello Inbound Voice 7 07-30-2013 10:52 PM
Virtual queue not able to report calls jintiam.loh@consiliuminc.com Inbound Voice 3 10-29-2010 11:46 AM
Overlap AHT query SamJ83 Workforce Management (WFM) 4 03-16-2010 02:12 AM
Virtual Queue Statistics gustavo.fiani Platform SDK 0 12-22-2009 04:45 AM
Virtual Hold sampsonr Genesys University / Training 2 03-10-2009 02:27 AM

Copyright 2008 - 2009, Genesys Telecommunications Laboratories, Inc.

Powered by vBulletin® Version 3.7.3
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
All Rights Reserved