[Asterisk-Users] App queue and all Agent busy

Anton Yurchenko phila at dg.net.ua
Thu Nov 27 07:51:50 MST 2003


Philipp von Klitzing wrote:

>Hi!
>
>  
>
>>but when both Agents are busy then still the called party does not get a 
>>busy signal.
>>
>>What I`d want is when both Agents are busy that the caller gets a busy, 
>>not the long tones, like the phone is ringing, but nobody answers it ( 
>>this is how this works now)
>>Any Ideas?
>>    
>>
>
>Method 1: Configure the queue to only take two callers
>
>  
>
what would callers get when the queue is full? that is still not such a 
good solution as there may be a variable number of operators.

>Method 2: Don't use queues at all and instead use a simple Dial() in 
>extensions.conf where you dial both agents extensions like
>
>exten => 1000,1,Dial(SIP/john&SIP/mary)
>exten => 1000,2, ... unavailable ...
>exten => 1000,102, ... busy ...
>
>  
>
Operators have a wrapup to do and such.

I`ve looked at the source of app_dial. and app_queue.c, and I found such 
a piece of code in app_dial.c:
                if (found < 0) {
                        if (numlines == numbusies) {
                                if (option_verbose > 2)
                                        ast_verbose( VERBOSE_PREFIX_2 
"Everyone
is busy at this time\n");
                                /* See if there is a special busy message */
                                if (ast_exists_extension(in, 
in->context, in->exten, in->priority + 101, in->callerid))
                                        in->priority+=100;
                        } else {
                                if (option_verbose > 2)
                                        ast_verbose( VERBOSE_PREFIX_2 
"No one is available to answer at this time\n");
                        }
                        *to = 0;

notice the part about priority, there is an almost identical code in 
app_queue.c:

                if (found < 0) {
                        if (numlines == numbusies) {
                                ast_log(LOG_DEBUG, "Everyone is busy at 
this time\n");
                        } else {
                                ast_log(LOG_NOTICE, "No one is answered 
queue %s\n", queue);
                        }
                                                                                

                        *to = 0;

almost the same without the part:

                                /* See if there is a special busy message */
                                if (ast_exists_extension(in, 
in->context, in->exten, in->priority + 101, in->callerid))
                                        in->priority+=100;


would it work if I merged them and code in app_queue.c looke like:

                if (found < 0) {
                        if (numlines == numbusies) {
                                ast_log(LOG_DEBUG, "Everyone is busy at 
this time\n");
                            /* See if there is a special busy message */
                            if (ast_exists_extension(in, in->context, 
in->exten, in->priority + 101, in->callerid))
                                            in->priority+=100;
                        } else {
                                ast_log(LOG_NOTICE, "No one is answered 
queue %s\n", queue);
                        }
                                                                                

                        *to = 0;

this is a production system and it better to know before I go in with 
hacked code.

This would be a very good functionality, I can setup a prompt, like "all 
operators are busy" and such.

thanks


>Cheers, Philipp
>
>
>_______________________________________________
>Asterisk-Users mailing list
>Asterisk-Users at lists.digium.com
>http://lists.digium.com/mailman/listinfo/asterisk-users
>
>  
>


-- 

Anton Yurchenko<phila at dg.net.ua>
Digital Generation





More information about the asterisk-users mailing list