[asterisk-bugs] [Asterisk 0012880]: Queue() uses cached information to determine whether queue is empty or not

noreply at bugs.digium.com noreply at bugs.digium.com
Thu Jun 19 18:54:27 CDT 2008


A NOTE has been added to this issue. 
====================================================================== 
http://bugs.digium.com/view.php?id=12880 
====================================================================== 
Reported By:                bcnit
Assigned To:                
====================================================================== 
Project:                    Asterisk
Issue ID:                   12880
Category:                   Applications/app_queue
Reproducibility:            always
Severity:                   minor
Priority:                   normal
Status:                     new
Asterisk Version:           1.6.0-beta9 
SVN Branch (only for SVN checkouts, not tarball releases): N/A 
SVN Revision (number only!):  
Disclaimer on File?:        N/A 
Request Review:              
====================================================================== 
Date Submitted:             06-18-2008 02:24 CDT
Last Modified:              06-19-2008 18:54 CDT
====================================================================== 
Summary:                    Queue() uses cached information to determine whether
queue is empty or not
Description: 

If I have a queue which is driven by realtime and Asterisk is not aware of
the queue (i.e. 'queue show' shows nothing), then if the queue is set with
'joinempty=no', when you try to queue a call to it, Asterisk bounces the
call out with QUEUESTATUS as JOINEMPTY.

Once Asterisk knows of the queue's existance, then realtime is checked to
see if the queue is empty or not and all works fine.

The only way I can get around this is to run a script when Asterisk starts
which interrogates the database to get the list of all queues run by
realtime and then issue an 'asterisk -rx "queue show QUEUE"' for each one
to populate the cache.

Please see bug report http://bugs.digium.com/view.php?id=12858 to which this is
probably related.

====================================================================== 

---------------------------------------------------------------------- 
 putnopvut - 06-19-08 18:54  
---------------------------------------------------------------------- 
When a caller joins a queue, app_queue does not use cached information. It
will attempt to load the queue and member information from realtime every
time a caller joins a realtime queue. In fact, the code when a caller joins
a queue uses the same function to get the realtime information that queue
show <queuename> does. It doesn't really make sense that one would work
properly and the other would not.

I tried to reproduce this issue myself but could not. Everything worked as
expected. Unfortunately, there are lots of possible reasons why the
scenario could be failing for you. To make matters worse, asking for
console output isn't going to do any good because there are no decent debug
messages that get printed at that point.

What I will do for this issue is to upload a patch which does not change
app_queue's behavior but adds a lot of console messages so that I can see
exactly what is happening when this failure occurs. The patch will most
likely be ready by tomorrow. 

Issue History 
Date Modified   Username       Field                    Change               
====================================================================== 
06-19-08 18:54  putnopvut      Note Added: 0088992                          
======================================================================




More information about the asterisk-bugs mailing list