Callbacks "Dial Lead" not working

All installation and configuration problems and questions

Moderators: gerski, enjay, williamconley, Op3r, Staydog, gardo, mflorell, MJCoate, mcargile, Kumba, Michael_N

Callbacks "Dial Lead" not working

Postby ZoVoS » Mon Jan 14, 2013 1:38 pm

Hello all. I have crawled out from my basement and off my free switch billing portal project to return to vicidial as my technicians seem to have encountered a problem they couldn't fix.
First off I run many servers most of them are updated to the latest SVN
We have noticed a problem after updating to the latest SVN (for our installations at-least.)
Various methods have been used to install Vicidial. Primarily Vicibox however some scratch installations are also in effect.

After the update when an agent selects a callback and attempts to dial nothing happens.
(that's not exactly true, you just cant see what happens by default)

I ran this through Firefox to find out where the problem occurred and I received

Code: Select all
TypeError: CFN_value is undefined
http://***.***********.com/agc/vicidial.php
Line 8537


This corresponds to line;
Code: Select all
CFN_value = CFN_value.replace(RGnl,'+');


In true sticky plaster fashion I have added the following;

Code: Select all
                                        else
                                                {
                                                var CFN_value = CFV_array[CFN_tick];
                                                }
///////////////////////////////////////ZOVOS EDIT///////////////////////////////////////
if (CFN_value===undefined)
{
alert("This popup should only appear when making a callback and is only temporary. please inform ********* if this popup is seen anywhere other than dialling a callback.");
CFN_value = '';
}
///////////////////////////////////////ZOVOS EDIT///////////////////////////////////////

                                        alert(CFV_array[CFN_tick],"  ",CFN_value);
                                        CFN_value = CFN_value.replace(RGnl,'+');
                                        CFN_value = CFN_value.replace(RGtab,'+');


This works fine and currently I haven't seen the popup appearing elsewhere in the system. Alas this is only a sticky plaster solution.
I have preformed a "svn blame" on the file and am currently looking for changes that would have caused the CFN_value to become undefined.
However this is going to take a while and i'm a tad worried about the havoc this may causeto the systems, I am quite lucky that I have a very good working relationship with all of my clients.


Additional information this occurs when the tick reaches 11

perhaps "if (CF_loaded=='1')" is suppose to fail so the ELSE kicks in and;
Code: Select all
                                        else
                                                {
                                                var CFN_value = CFV_array[CFN_tick];
                                                }

However this is only speculation as setting the value to 11 is also valid.
This is one of the few areas of the system I am not versed in as javascript is a nightmare for me.

Any additional information would be handy. Thanks in advance all.
ZoVoS
 
Posts: 58
Joined: Fri Aug 17, 2012 11:07 am

Re: Callbacks "Dial Lead" not working

Postby ZoVoS » Mon Jan 14, 2013 1:46 pm

apparently they are getting the popup quite regularly so it must be undefined quite a bit. I have suppressed the popup for now and will try and find why CFN_value is not defined.
ZoVoS
 
Posts: 58
Joined: Fri Aug 17, 2012 11:07 am

Re: Callbacks "Dial Lead" not working

Postby ZoVoS » Mon Jan 14, 2013 6:08 pm

Time for me to crawl back under my rock =P thanks all and I hope somebody has a better idea than I do of what is causing this issue.
ZoVoS
 
Posts: 58
Joined: Fri Aug 17, 2012 11:07 am

Re: Callbacks "Dial Lead" not working

Postby DomeDan » Tue Jan 15, 2013 7:37 am

Would be interesting to know the value of some of the variables.

you could write some javascript to make a get request to your web-server that posts the variables so you can look in the logs and check the values later on.

something like this http://stackoverflow.com/questions/2474 ... javascript
Code: Select all
function httpGet(theUrl)
    {
    var xmlHttp = null;

    xmlHttp = new XMLHttpRequest();
    xmlHttp.open( "GET", theUrl, false );
    xmlHttp.send( null );
    return xmlHttp.responseText;
    }

and add something like this where you added your alert():

httpGet('http://your-vicidial/callbacks_problem?CFN_tick=' + CFN_tick + '&CFV_array[CFN_tick]=' + CFV_array[CFN_tick] + '&CF_loaded=' + CF_loaded)

there is some debugging added to the code "CFN_debug" but I'm not very familiar with javascript, but you could also use a DOM editor to view the variables and other stuff (ctrl +shift + C in chromium)
Vicidial Partner. Region: Sweden/Norway.
Does Vicidial installation, configuration, customization, add-ons, CRM implementation, support, upgrading, network-related, pentesting etc. Remote and onsite assistance.
Email: domedan (at) gmail.com
DomeDan
 
Posts: 1226
Joined: Tue Jan 04, 2011 9:17 am
Location: Sweden

Re: Callbacks "Dial Lead" not working

Postby ZoVoS » Tue Jan 15, 2013 8:17 pm

///////////////////////////////////////ZOVOS EDIT///////////////////////////////////////

alert(CFV_array[CFN_tick]," ",CFN_value);

ye I was using the alert to show that off, I have been really busy and haven't had any time to look into the issue seriously as the sticky plaster seems to be holding. no news if this disrupts reports or not.


before I do any serious error checking I'm going to tear the script apart and knock up a flow diagram to track what's supposed to be happening at any given time. ill probably run a test server with an annoying number of popups to track what's happening at any given time =]


Also, before I get that far I want to run a check on some of the servers that are not updated to see if the variable is ever undefined and what the variable is defined as when they are preforming a call back. That way I can ensure that leaving it blank wont screw the system over to much, also ill have to check if everything is logging right and things match up with the manual logs.
ZoVoS
 
Posts: 58
Joined: Fri Aug 17, 2012 11:07 am

Re: Callbacks "Dial Lead" not working

Postby williamconley » Tue Jan 15, 2013 9:23 pm

I would be more interested to know if this particular issue occurs on a scratch or on a vicibox AND the actual version (as opposed to "latest"!).

Your method of upgrade would be nice to know as well, perhaps the version from which you last upgraded when this function was working would help, too.

And just to be funny: Did you request "sample confs" to be installed during the upgrade? And are there any other customizations?

Probably a good idea to install latest svn in a vmware and simulate the issue and see if you can duplicate it. Try to find a commonality (call path, agent, server ... something) to allow you to duplicate the error. That would, of course, make it much easier to troubleshoot.
Vicidial Installation and Repair, plus Hosting and Colocation
Newest Product: Vicidial Agent Only Beep - Beta
http://www.PoundTeam.com # 352-269-0000 # +44(203) 769-2294
williamconley
 
Posts: 20258
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Callbacks "Dial Lead" not working

Postby ZoVoS » Wed Jan 16, 2013 1:28 pm

BAH!!!!!!!!!!

I just updated another 2 clients (running 100% clean installs) to the latest SVN, and they have no problems.
unfortunately I have made multiple changes to most of the servers. There is only 1 concerning me as I am sure the server has no customisation what so ever.

Most of the servers showing this error are heavily customised, I will try copying the entire web directory and .PL script list from a functioning server -> the server that is concerning me and see if it sorts the issue. However i'm sure it pulls the latest webfolder and PL scripts when the install.pl is executed.

as this isn't happening with the other servers I have updated today I suppose ill work on this my self as I can't expect anybody to be able to error check it if i'm having trouble reproducing it my self.

Thanks for comments ill keep this page updated when I find the root cause.

oh and no I never copy "sample confs" ^__^
ZoVoS
 
Posts: 58
Joined: Fri Aug 17, 2012 11:07 am

Re: Callbacks "Dial Lead" not working

Postby williamconley » Wed Jan 16, 2013 2:26 pm

I always copy sample confs. All our servers have STOCK confs. This way, when The Vicidial Group adds a new feature that requires a new extension (or anything is altered!) we do not have to diff our confs and theirs and add their changes into our conf files. Much simpler to keep our conf files stock. And upgrades always succeed. :)
Vicidial Installation and Repair, plus Hosting and Colocation
Newest Product: Vicidial Agent Only Beep - Beta
http://www.PoundTeam.com # 352-269-0000 # +44(203) 769-2294
williamconley
 
Posts: 20258
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)

Re: Callbacks "Dial Lead" not working

Postby ZoVoS » Thu Jan 17, 2013 1:20 pm

=P I suppose I should copy them, I prefer not having to remake changes to the files but tbh I should extract most of my changes in the conf files and make them include files. I have a bit of time for testing. Ill check the SVN to see when the conf files were last updated and what changed in them (in case that could be of any help).
ZoVoS
 
Posts: 58
Joined: Fri Aug 17, 2012 11:07 am

Re: Callbacks "Dial Lead" not working

Postby ZoVoS » Thu Jan 17, 2013 1:48 pm

the most neolitic outdated server im currently running (and they refuse to make any changes to it =] if its not broke don't fix it) is SVN 1795

The only changes since then are;

1899 mattf ;exten => _+X.,1,AGI(agi-DID_route.agi)
1899 mattf ; If you have DIDs that arrive with a plus sign at the beginning then uncomment
1899 mattf
1804 mattf maxmessage=300

Nice to know mind.


I dont suppose you know what this change was suppose to fix?

1915 mattf # Copyright (C) 2013 Matt Florell <vicidial@gmail.com> LICENSE: AGPLv2
1915 mattf # 130103-0808 - Added CLI options for delay to be used with auto-dial and FILL processes
1915 mattf $autodial_delay='';
1915 mattf $adfill_delay='';
1915 mattf print " [-test] = test\n";
1915 mattf print " [-autodial-delay=X] = setting delay milliseconds on local auto-dial process\n";
1915 mattf print " [-adfill-delay=X] = setting delay milliseconds on auto-dial FILL process\n";
1915 mattf if ($args =~ /-autodial-delay=/i) # CLI defined delay
1915 mattf {
1915 mattf @CLIvarADARY = split(/-autodial-delay=/,$args);
1915 mattf @CLIvarADARX = split(/ /,$CLIvarADARY[1]);
1915 mattf if (length($CLIvarADARX[0])>0)
1915 mattf {
1915 mattf $CLIautodialdelay = $CLIvarADARX[0];
1915 mattf $CLIautodialdelay =~ s/\/$| |\r|\n|\t//gi;
1915 mattf $CLIautodialdelay =~ s/\D//gi;
1915 mattf if ( ($CLIautodialdelay > 0) && (length($CLIautodialdelay)> 0) )
1915 mattf {$autodial_delay = "--delay=$CLIautodialdelay";}
1915 mattf if ($DB > 0) {print "AD Delay set to $CLIautodialdelay $autodial_delay\n";}
1915 mattf }
1915 mattf @CLIvarADARY=@MT; @CLIvarADARY=@MT;
1915 mattf }
1915 mattf if ($args =~ /-adfill-delay=/i) # CLI defined delay
1915 mattf {
1915 mattf @CLIvarADFARY = split(/-autodial-delay=/,$args);
1915 mattf @CLIvarADFARX = split(/ /,$CLIvarADFARY[1]);
1915 mattf if (length($CLIvarADFARX[0])>0)
1915 mattf {
1915 mattf $CLIadfilldelay = $CLIvarADFARX[0];
1915 mattf $CLIadfilldelay =~ s/\/$| |\r|\n|\t//gi;
1915 mattf $CLIadfilldelay =~ s/\D//gi;
1915 mattf if ( ($CLIadfilldelay > 0) && (length($CLIadfilldelay)> 0) )
1915 mattf {$adfill_delay = "--delay=$CLIadfilldelay";}
1915 mattf if ($DB > 0) {print "ADFILL Delay set to $CLIadfilldelay $adfill_delay\n";}
1915 mattf }
1915 mattf @CLIvarADFARY=@MT; @CLIvarADFARY=@MT;
1915 mattf }
1915 mattf if ($DB > 0) {print "CU3 Delay set to $CLIdelay $cu3way_delay\n";}
1915 mattf if ($args =~ /-test/i)
1915 mattf `/usr/bin/screen -d -m -S ASTVDauto $PATHhome/AST_VDauto_dial.pl $autodial_delay`;
1915 mattf `/usr/bin/screen -d -m -S ASTVDautoFILL $PATHhome/AST_VDauto_dial_FILL.pl $adfill_delay`;


I have lost of alterations to various servers bin/ADMIN_keepalive_ALL.pl and just wondering if I should prioritise adding it in.
ZoVoS
 
Posts: 58
Joined: Fri Aug 17, 2012 11:07 am

Re: Callbacks "Dial Lead" not working

Postby DomeDan » Thu Jan 17, 2013 3:04 pm

svn revision 1915 got this comments:
------------------------------------------------------------------------
r1915 | mattf | 2013-01-03 14:29:22 +0100 (tor, 03 jan 2013) | 2 lines

Added new ADMIN keepalive options for setting the delay on the auto-dial and auto-dialFIll processes.
Notes added on agent-only server optimizations in clusters
------------------------------------------------------------------------


and here's a piece of documentation added to LOAD_BALANCING.txt
USE OF AGENT-ONLY AND DIAL-ONLY SERVERS ON YOUR CLUSTER:

If you are using servers where agents only log in and handle calls, but no calls are placed out from it, then you can use the new delay options on those servers to enhance efficient operations. The --autodial-delay=X option in the ADMIN_keepalive_ALL.pl script will allow you to set the delay to 100 milliseconds for these agent-only servers(the default is 2500ms). Lowering the delay for agent-only servers makes the auto-dial FILL process more responsive to the changes in the agent state on the agent-only servers which will enhance how your cluster operates. You can also use the --adfill-delay=X CLI option for the ADMIN_keepalive_ALL.pl script on the server that is running the FILL process and lower it as well if you have a larger cluster. The default of that process is also 2500ms, but you can lower it down to 500ms if needed.
Vicidial Partner. Region: Sweden/Norway.
Does Vicidial installation, configuration, customization, add-ons, CRM implementation, support, upgrading, network-related, pentesting etc. Remote and onsite assistance.
Email: domedan (at) gmail.com
DomeDan
 
Posts: 1226
Joined: Tue Jan 04, 2011 9:17 am
Location: Sweden

Re: Callbacks "Dial Lead" not working

Postby williamconley » Thu Jan 17, 2013 7:33 pm

ZoVoS wrote:=P I suppose I should copy them, I prefer not having to remake changes to the files but tbh I should extract most of my changes in the conf files and make them include files. I have a bit of time for testing. Ill check the SVN to see when the conf files were last updated and what changed in them (in case that could be of any help).

virtually anything you need to put into a conf file can be put into a custom extension in system settings or one of the other custom locations. or just directly in a carrier if you need it in sip.conf or iax.conf
Vicidial Installation and Repair, plus Hosting and Colocation
Newest Product: Vicidial Agent Only Beep - Beta
http://www.PoundTeam.com # 352-269-0000 # +44(203) 769-2294
williamconley
 
Posts: 20258
Joined: Wed Oct 31, 2007 4:17 pm
Location: Davenport, FL (By Disney!)


Return to Support

Who is online

Users browsing this forum: Google [Bot] and 96 guests