aboutsummaryrefslogtreecommitdiffstats
path: root/apps/app_queue.c
AgeCommit message (Collapse)AuthorFilesLines
2007-08-08Changing a bit of logic so that someone will NEVER exit the queue on timeout ↵mmichelson1-11/+8
unless they have enabled the 'n' option. This commit relates to issue #10320. Thanks to jfitzgibbon for detailing the idea behind this code change. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@78575 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-01Fixes an issue I introduced to queues wherein a queue with joinempty=yes ↵mmichelson1-0/+5
would kick people out of the queue because of erroneously thinking the 'n' option was in use. (closes issue #10320, reported by jfitzgibbon, patched by me, tested by blitzrage and me) Thank you blitzrage for all the testing you've done lately with queues! It's much appreciated! git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@77854 f38db490-d61c-443f-a65b-d21fe96a405b
2007-08-01If a queue uses dynamic realtime members, then the member list should be ↵mmichelson1-0/+54
updated after each attempt to call the queue. This fixes an issue where if a caller calls into a queue where no one is logged in, they would wait forever even if a member logged in at some point. (closes issue #10346, reported by and tested by blitzrage, patched by me) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@77852 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-24Added a membercount variable to call_queue struct which keeps track of the ↵mmichelson1-11/+19
number of logged in members in a particular queue. This makes it so that the 'n' option for Queue() can act properly depending on which strategy is used. If the strategy is roundrobin, rrmemory, or ringall, we want to ring each phone once before moving on in the dialplan. However, if any other strategy is used, we will only ring one phone since it cannot be guaranteed that a different phone will ring on subsequent attempts to ring a phone. As a side effect of this, the QUEUE_MEMBER_COUNT dialplan function now just reads the membercount variable instead of traversing through the member list to figure out how many members there are. Special thanks to blitzrage for helping to test this out. (closes issue #10127, reported by bcnit, patched by me, tested by blitzrage) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@76801 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-20Move makeannouncement variable declaration to proper place.file1-2/+2
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@76054 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-19The diff on this looks pretty big but all I did was remove a pointless if ↵mmichelson1-81/+78
statement (always evaluates true). git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@75978 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-19Changes in handling return values of several functions in app_queue. This ↵mmichelson1-96/+70
all started as a fix for issue #10008 but now includes all of the following changes: 1. Simplifying the code to handle positive return values from ast API calls. 2. Removing the background_file function. 3. The fix for issue #10008 (closes issue #10008, reported and patched by dimas) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@75969 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-18Merged revisions 75657 via svnmerge from dhubbard1-1/+1
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r75657 | dhubbard | 2007-07-18 12:48:33 -0500 (Wed, 18 Jul 2007) | 1 line removed the word 'pissed' from ast_log(...) function call for BE-90 ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@75658 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-10Merged revisions 74427 via svnmerge from qwell1-10/+13
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r74427 | qwell | 2007-07-10 14:57:20 -0500 (Tue, 10 Jul 2007) | 6 lines Fix an issue where it was possible to have a service level of over 100% Between the time recalc_holdtime and update_queue was called, it was possible that the call could have been hungup. Move both additions to the same place, so this won't happen. Issue 10158, initial patch by makoto, modified by me. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@74428 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-09Forgot to get rid of an extraneous debug message.mmichelson1-1/+0
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@74122 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-09The n option for Queue should make the queue exit immediately after failure ↵mmichelson1-12/+14
to reach any members and should not be dependent on the timeout value passed to Queue (closes issue #10127, reported by bcnit, repaired by me) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@74120 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-05Correcting a minor CLI bug I found. When issuing the queue show command, if ↵mmichelson1-2/+9
you type queue show and then press tab, you can continue pressing tab and it will keep auto-completing queue names even though only 1 queue can be used as an argument. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@73400 f38db490-d61c-443f-a65b-d21fe96a405b
2007-07-05Merged revisions 73315 via svnmerge from file1-2/+1
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r73315 | file | 2007-07-05 10:19:17 -0300 (Thu, 05 Jul 2007) | 2 lines Reset ServicelevelPerf variable back to 0 if we are unable to calculate it each time... otherwise we will get previous values. (issue #10117 reported by noriyuki) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@73316 f38db490-d61c-443f-a65b-d21fe96a405b
2007-06-27Merged revisions 72327 via svnmerge from file1-0/+2
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r72327 | file | 2007-06-27 18:43:11 -0400 (Wed, 27 Jun 2007) | 2 lines Fix issue where queue log events might be missing. (issue #7765 reported by mtryfoss) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@72328 f38db490-d61c-443f-a65b-d21fe96a405b
2007-06-07Fix loading persistent queue members when using realtime configuration for ↵russell1-1/+5
queues. Also, remove an unneeded leading slash for the astdb family. (issue #9911, patch by atis) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@68280 f38db490-d61c-443f-a65b-d21fe96a405b
2007-05-22Merged revisions 65389 via svnmerge from russell1-0/+2
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r65389 | russell | 2007-05-22 08:07:03 -0500 (Tue, 22 May 2007) | 4 lines Fix a memory leak that I just noticed in the device state handling in app_queue. On most device state changes, it would leak roughly 8 to 64 bytes (the length of the name of the device). ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@65394 f38db490-d61c-443f-a65b-d21fe96a405b
2007-05-18Fix a small bug I noticed while working on something else. app_queue did notrussell1-0/+1
unregister its device state monitoring callback in unload_module(). So, this would make Asterisk crash on the first device state change after you unload the module. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@64868 f38db490-d61c-443f-a65b-d21fe96a405b
2007-04-20Merged revisions 61692 via svnmerge from qwell1-1/+1
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r61692 | qwell | 2007-04-20 14:49:54 -0500 (Fri, 20 Apr 2007) | 5 lines If the '* to hangup' option is not enabled, we don't need to disable * as a valid exit key. If it was enabled, this statement would've never been checked in the first place. Issue #9552 ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@61694 f38db490-d61c-443f-a65b-d21fe96a405b
2007-04-09Use the appropriate interface name with COMPLETECALLER.qwell1-1/+1
Issue 9395. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@61022 f38db490-d61c-443f-a65b-d21fe96a405b
2007-04-08Allow app_queue to use MONITOR_EXEC even if MONITOR_OPTIONS is not set. ↵file1-1/+1
(issue #9495 reported by cduffy) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@60762 f38db490-d61c-443f-a65b-d21fe96a405b
2007-02-17Add missing membername option to AddQueueMember documentation. (issue #9088 ↵file1-1/+1
reported by seanbright) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@55219 f38db490-d61c-443f-a65b-d21fe96a405b
2007-02-17Make the 'i' option of Queue actually work. (issue #8986 reported by utis)file1-1/+4
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@55129 f38db490-d61c-443f-a65b-d21fe96a405b
2007-02-02 I'm baaaaaaaaaack. :)bweschke1-0/+4
Post a warning to the console that things might possibly be misconfigured when queue member's states are still 'Not in Use' when we're about to bridge them with a caller from queue. Also, put some documentation quoted from oej's queues.txt efforts started in /trunk today. This commit puts #7433 into feedback state for 1.4, and pending no further negative feedback, it will finally be closed. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@53129 f38db490-d61c-443f-a65b-d21fe96a405b
2007-02-01Change debug level for state change message that is not really informative ↵oej1-1/+1
when debugging app_queue git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@53081 f38db490-d61c-443f-a65b-d21fe96a405b
2007-01-31Merged revisions 53045 via svnmerge from russell1-0/+1
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r53045 | russell | 2007-01-31 15:25:11 -0600 (Wed, 31 Jan 2007) | 3 lines Fix a bunch of places where pthread_attr_init() was called, but pthread_attr_destroy() was not. ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@53046 f38db490-d61c-443f-a65b-d21fe96a405b
2007-01-31Only changed the paused status in an existing queue member if the pausedrussell1-1/+2
column exists. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@53037 f38db490-d61c-443f-a65b-d21fe96a405b
2007-01-31Instead of always creating a realtime queue member as unpaused, read therussell1-3/+12
"paused" column and use that value for the paused status of the member. (issue #8949, jmls) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@53035 f38db490-d61c-443f-a65b-d21fe96a405b
2007-01-27Merged revisions 52415 via svnmerge from file1-4/+4
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r52415 | file | 2007-01-26 21:09:10 -0500 (Fri, 26 Jan 2007) | 2 lines Make COMPLETECALLER and COMPLETEAGENT output to queue_log follow documentation. (issue #7677 reported by amilcar) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@52416 f38db490-d61c-443f-a65b-d21fe96a405b
2007-01-05reduce stack consumption for AMI and AMI/HTTP requests by nearly 20K in most ↵kpfleming1-21/+21
cases git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@49676 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-10if adding a queue member is LOG_NOTICE, then removing them should be ↵kpfleming1-1/+1
LOG_NOTICE, not LOG_DEBUG git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@47433 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-10reflect addition/removal of dynamic queue members in queue_log, so that ↵kpfleming1-0/+6
people using dialplan replacement for AgentCallbackLogin can still track login/logout (issue #7736, reported/patched by whoiswes but this commit was written by me and covers all three paths for AQM/RQM) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@47432 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-02More changes making the CLI more consistent with "category verb arguments" ↵tilghman1-5/+5
(continuation of issue 8236) git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@47053 f38db490-d61c-443f-a65b-d21fe96a405b
2006-11-02Reverse change of "show" to "list" and make several other commands more ↵tilghman1-20/+11
consistent with "category verb arguments" git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@47051 f38db490-d61c-443f-a65b-d21fe96a405b
2006-10-25update warning message to include "agi" option (issue #8225, jmls)russell1-1/+1
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@46249 f38db490-d61c-443f-a65b-d21fe96a405b
2006-10-25apparently developers are still not aware that they should be use ↵kpfleming1-17/+9
ast_copy_string instead of strncpy... fix up many more users, and fix some bugs in the process git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@46200 f38db490-d61c-443f-a65b-d21fe96a405b
2006-10-04update thread creation code a bitkpfleming1-1/+1
reduce standard thread stack size slightly to allow the pthreads library to allocate the stack+data and not overflow a power-of-2 allocation in the kernel and waste memory/address space add a new stack size for 'background' threads (those that don't handle PBX calls) when LOW_MEMORY is defined git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@44378 f38db490-d61c-443f-a65b-d21fe96a405b
2006-10-03Merged revisions 44296 via svnmerge from kpfleming1-3/+7
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r44296 | kpfleming | 2006-10-03 15:14:13 -0500 (Tue, 03 Oct 2006) | 2 lines fix a logic error in my previous fix to the queue reload code ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@44298 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-28Fix incorrect argument order for member names, on persisted members.qwell1-1/+1
Issue 8047, patch by jmls. git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@43944 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-28Merged revisions 43916 via svnmerge from kpfleming1-16/+13
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r43916 | kpfleming | 2006-09-28 12:31:57 -0500 (Thu, 28 Sep 2006) | 2 lines fix buggy (and overly complex) loop used during reload of app_queue for static member list updating ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@43919 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-28Merged revisions 43897 via svnmerge from bweschke1-2/+16
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r43897 | bweschke | 2006-09-28 12:37:15 -0400 (Thu, 28 Sep 2006) | 3 lines app_queue is comparing the device names incorrectly while checking their statuses. It's internal list of interfaces includes the dial string, while the argument passed to this function does not have the dial string (/n for a local channel). This causes it to ignore the device state changes because it thinks it belongs to none of its members. (#8040 reported and patch by tim_ringenbach) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@43899 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-28Merged revisions 43871 via svnmerge from bweschke1-1/+4
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r43871 | bweschke | 2006-09-28 11:18:05 -0400 (Thu, 28 Sep 2006) | 3 lines Fix race condion crash with get_member_status (#7864 - tim_ringenbach reported and patched) ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@43873 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-28 Autopause not working for queue members. (#8042 - jmls reported and patch)bweschke1-2/+4
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@43864 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-20Constify the result of a config retrieval function, to avoid mutilation ↵tilghman1-3/+3
(issue 7983). git-svn-id: http://svn.digium.com/svn/asterisk/trunk@43364 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-20Fix a segfault that was reported by jcmoore in #asterisk-bugs on IRC.qwell1-1/+1
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@43357 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-20We need to persist the member name alsoqwell1-2/+2
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@43322 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-20Add a "member name" to queue members.qwell1-60/+117
Add option to the various methods of adding a queue member, to add the "member name". Member name is used in (most) queue log records, in place of the interface name. This makes it consistent, so that you can log in from any device, and still be logged as "member name" git-svn-id: http://svn.digium.com/svn/asterisk/trunk@43316 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-19similar patch for verbose vs debug with minor changesmogorman1-1/+1
bug 2617 git-svn-id: http://svn.digium.com/svn/asterisk/trunk@43272 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-18merge qwell's CLI verbification workkpfleming1-43/+60
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@43212 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-03 This was added to app_dial a while back, and now it's in app_queue as well. ↵bweschke1-4/+14
Provide an option to prevent members of the queue from forwarding calls from the queue to somewhere else. git-svn-id: http://svn.digium.com/svn/asterisk/trunk@41901 f38db490-d61c-443f-a65b-d21fe96a405b
2006-09-03Merged revisions 41882 via svnmerge from bweschke1-0/+1
https://origsvn.digium.com/svn/asterisk/branches/1.2 ........ r41882 | bweschke | 2006-09-03 13:38:22 -0400 (Sun, 03 Sep 2006) | 3 lines Make sure the forwarded channel inherits variables appropriately when we receive a call forward in the queue. (#7867 - raarts reported and patched) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@41883 f38db490-d61c-443f-a65b-d21fe96a405b