cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1197
Views
0
Helpful
27
Replies

Need Help in advising how the Copy and Migrate Existing Cisco CCX 3.5 Scripts to New Cisco CCX 9.0.1

gsriraman
Level 1
Level 1

We are installing the Cisco CCX 9.0.1. The Mandate is data should  be migrated as it is. of The Scripts being used presently have to be as it is in the new system.

 

Can some one please help me in suggesting the migration  these scripts .

 

e.g. Copy the script from the CCX CRS 3.5

 

Upload them to CCX 9.0.1

 

ANy additional suggestions welecom

27 Replies 27

Here is the MIVR Trace

I don't see anything unusual here, except for an error message, but it's more like a configuration error.

Enable debugging for

LIB_MEDIA

CHANNEL_MGR

CONTACT_MGR

PROMPT_MGR

SCRIPT_MGR

STEP_CALL_CONTROL

STEP_MEDIA_CONTROL

STEPS_CONTACT

STEPS_PROMPT

SS_CM

SS_TEL

Then make a test call. Note the calling and the called number. I will need that information so I don't need to read megabytes of text.

G.

Please find the Log files as you have asked.

 

Number we called is 42155715 ( FXO connected on Router)

 

Number we called from  67974077 or 67974078 or 25182373

Hi,

alright, I can see it now. This is the error message we are looking for:

517897: Jul 22 16:49:04.307 IST %MIVR-APP_MGR-3-TASK_ABORTED:Application task aborted: Application=App[name=Welcome_Msg,type=Cisco Script Application,id=0,desc=Welcome_Msg,enabled=true,max=2,valid=true,cfg=[ApplicationConfig[schema=ApplicationConfig,time=2014-07-21 13:38:32
.0,recordId=18,desc=Welcome_Msg,name=Welcome_Msg,type=Cisco Script Application,id=0,enabled=true,sessions=2,script=SCRIPT[Main_LIPDEL_AGRI.aef],defaultScript=,vars=[],defaultVars=null]]],Application Trigger=ContactApplicationTrigger[time=1406027931026,locale=en_US,cfg=JTAPI
TriggerConfig[schema=ApplicationTriggerConfig,time=2014-07-17 15:32:18.0,recordId=3,desc=Cisco JTAPI Trigger,name=1234,type=Cisco JTAPI Trigger,appName=Welcome_Msg,enabled=true,sessions=2,idleTimeout=5000,locale=en_US,parms={},taskGroups=[],controlClass=class com.cisco.call
.CallControlChannel,controlGroupId=2,contactGroups=[GroupInfo[class=com.cisco.dialog.DialogChannel,id=0]],dn=1234,redirectCSS=default,cmDeviceName=UCCSRP,cmDeviceInvalid=false,cmDescription=WelcomeRP,cmDevicePoolUUID={1B1B9EB6-7803-11D3-BDF0-00108302EAD1},cmDevicePoolName=D
efault,cmCallingSearchSpaceUUID={9320b4b0-7121-04e8-f647-3d7d4bf2646d},cmCallingSearchSpaceName=CSS_Internal,cmLocationUUID={29C5C1C4-8871-4D1E-8394-0B9181E8C54D},cmLocationName=Hub_None,cmPartitionUUID={D603CEF7-0516-E80C-F186-EE90AC43CF7A},cmPartitionName=PT_Intercom,cmVo
iceMailProfileUUID={00000000-1111-0000-0000-000000000000},cmVoiceMailProfileName=NoVoiceMail,cmCallPickUpGroupUUID=,cmCallPickUpGroupName=,cmDisplay=,cmExternalPhNumMask=,cmFwdBusyVM=false,cmFwdBusyDest=,cmFwdBusyCSSUUID=,cmFwdBusyCSSName=None,cmAlertingNameAscii=,cmPresenc
eGroupUUID=ad243d17-98b4-4118-8feb-5ff2e1b781ac,cmPresenceGroupName=Standard Presence group,campaignID=-1],contact=JTAPICallContact[id=65,implId=18212/1,state=STATE_ANSWERED_IDX,inbound=true,App name=Welcome_Msg,task=27000000070,session=2000000024,seq num=0,cn=1234,dn=1234,
cgn=Unknown,ani=null,dnis=null,clid=null,atype=DIRECT,lrd=null,ocn=1234,route=RP[num=1234],OrigProtocolCallRef=000000000000472401EEF34800000000,DestProtocolCallRef=null,TP=2005]],Task id=27000000070,Task Class=class com.cisco.app.impl.WFWorkflowAppDebugTaskWrapper,Exception
=com.cisco.expression.ExpressionTargetException: unable to convert string into a number; nested exception is:
        java.lang.NumberFormatException: For input string: "Unknown"
517898: Jul 22 16:49:04.307 IST %MIVR-APP_MGR-3-EXCEPTION:com.cisco.expression.ExpressionTargetException: unable to convert string into a number; nested exception is:
517899: Jul 22 16:49:04.307 IST %MIVR-APP_MGR-3-EXCEPTION:      java.lang.NumberFormatException: For input string: "Unknown"

Apparently, you are trying to set a string value to a local variable with the int type. Probably there is a Set step with this expression: intClid= strClid. The string value in this case is "Unknown" - this can never be assigned to an int variable.

Why are you doing this?

G.

Dear Gergely Szabo,

As you are aware, I have been unable to get a scripting guy locally even on a billable basis.

Having said that, we have just changed the paths in the existing script and it is working so far.

As I said before, the calls from within the network i.e. from IP phone DN 2050 to CTI Route Point 1234 is working beautifully.

It is when I make a call from outside to the number details given to you that it is giving problems.

So if you can suggest a solution, do let me know.  My reasoning is it could be because of CLID to be displayed or saved.

 

In the meantime, I am calling the customer to ask the reasons. Since this was done more than 5 years back, I am very sure they will not have an answer.

If you can suggest some work around, it will help. This is in the  2nd Script in subflow. I am attaching it alongwith. The First opening script you already have.

 

Another question? Could it be an issue of the FXO (Analog ) line , .

Do you think it will get resolved if we test it on a PRI ?

 

 

 

regards

 

 

 

Remove the Set intClid = strClid step from the Eng_LIPDEL_AGRI.aef script. The variable intClid is not referenced anywhere. 

The root cause of the problem is that the CLID is not sent, or the string "unknown" is sent and it cannot be cast into an int variable.

G.

Dear Gergely Szabo,

 

The step suggested by you did not work

 

I am attaching the Logs and the revised script

 

 

Hi,

I see. This way: you did not refresh the application/script because I can still see the system is trying to execute it:

 

562173: Jul 22 18:21:43.438 IST %MIVR-ENG-7-UNK:Execute step of Task 27000000091 : Set intClid = strClid
562174: Jul 22 18:21:43.439 IST %MIVR-APP_MGR-3-TASK_ABORTED:Application task aborted: Application=App[name=Welcome_Msg,type=Cisco Script Application,id=0,desc=Welcome_Msg,enabled=true,max=2,valid=true,cfg=[ApplicationConfig[schema=ApplicationConfig,time=2014-07-21 13:38:32
.0,recordId=18,desc=Welcome_Msg,name=Welcome_Msg,type=Cisco Script Application,id=0,enabled=true,sessions=2,script=SCRIPT[Main_LIPDEL_AGRI.aef],defaultScript=,vars=[],defaultVars=null]]],Application Trigger=ContactApplicationTrigger[time=1406033491082,locale=en_US,cfg=JTAPI
TriggerConfig[schema=ApplicationTriggerConfig,time=2014-07-22 17:56:10.0,recordId=9,desc=Cisco JTAPI Trigger,name=1234,type=Cisco JTAPI Trigger,appName=Welcome_Msg,enabled=true,sessions=2,idleTimeout=5000,locale=en_US,parms={},taskGroups=[],controlClass=class com.cisco.call
.CallControlChannel,controlGroupId=2,contactGroups=[GroupInfo[class=com.cisco.dialog.DialogChannel,id=0]],dn=1234,redirectCSS=default,cmDeviceName=UCCSRP,cmDeviceInvalid=false,cmDescription=WelcomeRP,cmDevicePoolUUID={1B1B9EB6-7803-11D3-BDF0-00108302EAD1},cmDevicePoolName=D
efault,cmCallingSearchSpaceUUID={9320b4b0-7121-04e8-f647-3d7d4bf2646d},cmCallingSearchSpaceName=CSS_Internal,cmLocationUUID={29C5C1C4-8871-4D1E-8394-0B9181E8C54D},cmLocationName=Hub_None,cmPartitionUUID={D603CEF7-0516-E80C-F186-EE90AC43CF7A},cmPartitionName=PT_Intercom,cmVo
iceMailProfileUUID={00000000-1111-0000-0000-000000000000},cmVoiceMailProfileName=NoVoiceMail,cmCallPickUpGroupUUID=,cmCallPickUpGroupName=,cmDisplay=,cmExternalPhNumMask=,cmFwdBusyVM=false,cmFwdBusyDest=,cmFwdBusyCSSUUID=,cmFwdBusyCSSName=None,cmAlertingNameAscii=,cmPresenc
eGroupUUID=ad243d17-98b4-4118-8feb-5ff2e1b781ac,cmPresenceGroupName=Standard Presence group,campaignID=-1],contact=JTAPICallContact[id=77,implId=18224/1,state=STATE_ANSWERED_IDX,inbound=true,App name=Welcome_Msg,task=27000000091,session=2000000036,seq num=0,cn=1234,dn=1234,
cgn=Unknown,ani=null,dnis=null,clid=null,atype=DIRECT,lrd=null,ocn=1234,route=RP[num=1234],OrigProtocolCallRef=000000000000473001EEF36E00000000,DestProtocolCallRef=null,TP=2003]],Task id=27000000091,Task Class=class com.cisco.app.impl.WFWorkflowAppDebugTaskWrapper,Exception
=com.cisco.expression.ExpressionTargetException: unable to convert string into a number; nested exception is:
        java.lang.NumberFormatException: For input string: "Unknown"


I ran a deeper analysis on your script and I see this variable intClid is used later in a database insert. So we need this variable anyway. But we need to handle the conversion of strClid to an int type more gracefully.

Could you please insert an If step after the Get Call Contact Info step:

If (strClid.matches("\d*"))

True: Set intClid = Integer.parseInt(strClid)

False: Set intClid = 0

This means: if the value of the strClid variable matches the regex pattern \d* (meaning it's a number) then the value will be parsed using the Integer.parseInt method. However, if the value of the strClid variable does not match the above regex pattern, it would assign 0 to intClid meaning something non-numeric came as the calling number (probably "unknown").

And please always remember to refresh the application and the script after making updates to your script.

G.

Dear Greg,

We got the service provider to send the CLID and that resolved the issue.

AT a later stage, we have reached one more error.

The call flow states that you have to save your voice query in oracle. So when the user confirms the query by pressing 1, is supposed to save it in Oracle.

The Scripts sends the instructions , Oracle receives the query and generates the ID, but the wav files does not get inserted.

It says SQL exception

EXECUTE_SQL_UPDATE_EXCEPTION:EXECUTE_SQL_UPDATE_EXCEPTION

150842: Jul 23 17:58:10.901 IST %MIVR-STEPS_DB-7-UNK:Task:27000000023 SQL exception: java.sql.SQLException: Io exception: Connection reset SQL State: null Error Code: 17002

150843: Jul 23 17:58:10.901 IST %MIVR-APP_MGR-3-STEP_FAILURE:Failure to execute a step: Application=App[name=OWI_LIPDEL_MAIN_APPLN,type=Cisco Script Application,id=1,desc=OWI_LIPDEL_MAIN_APPLN,enabled=true,max=30,valid=true,cfg=[ApplicationConfig[schema=ApplicationConfig,time=2014-07-

 

in Google it says SQL exception is network adapter connection issue.

However this was never the issue with us as I had kept the connection on with continuous ping also.

 

We tested this number of times.

 

Please help, I am also attaching the script once more

 

 

I am attaching the entire log

 

 

 

I have attached the log of ye

 

 

Good morning,

I have to disagree with the approach you chose when solving the CLID issue. No provider can guarrantee that the CLID would always be available. I can't imagine a reason why you did not implement the step I recommended. But again, if you feel comfortable with such a hidden bomb in your script, it's your choice.

About the database error: with all due respect, whoever wrote this script, was a bad programmer or not a programmer at all. Converting Dates to String and then concatenating them like there's no tomorrow is something a sane person would never do.

Why I am saying this: the problem actually lies in this code block (yes, it is in your script, look closer):

jCurrent_Date = new java.util.Date();
strCurrent_Date = jCurrent_Date.toLocaleString();
intCurrent_Date_Length = strCurrent_Date.length();
if (intCurrent_Date_Length == 24) {
    strMonth = strCurrent_Date.subString(0,3);
    strDate =  strCurrent_Date.substring(4,6);
    strYear =  strCurrent_Date.substring(7,12);
} else {
    strMonth = strCurrent_Date.substring(0,3);
    strDate =  strCurrent_Date.substring(4,5);
    strYear =  strCurrent_Date.substring(7,11);
}
strToday_Date = strToday_Date.concat(strDate + "-");
strToday_Date = strToday_Date.concat(strMonth + "-");
strToday_Date = strToday_Date.concat(strYear);

This would yield 2-Jul- 201 today and this is unacceptable by the database. This is exactly what we see in the error message as well:

150839: Jul 23 17:58:10.680 IST %MIVR-STEPS_DB-7-UNK:DBWriteStep: varName = strToday_Date; tokenIndex = 276
150840: Jul 23 17:58:10.680 IST %MIVR-STEPS_DB-7-UNK:DBWriteStep: variable value = 2-Jul- 201
150841: Jul 23 17:58:10.901 IST %MIVR-SS_DB-3-EXECUTE_SQL_UPDATE_EXCEPTION:EXECUTE_SQL_UPDATE_EXCEPTION

The solution is to insert a Set step with the following:

Set strToday_Date = 

{

String pattern = "dd-MMM-yyyy";
java.text.SimpleDateFormat sdf = new java.text.SimpleDateFormat(pattern);
String formattedDate = sdf.format(new java.util.Date());
return formattedDate;

}

Add this step right after the annotation that starts Insert max(QUERYREPLYMEDIAID)+1

ADJUST THE SCRIPT AND THEN REFRESH BOTH THE SCRIPT AND THE APPLICATION IN THE APPADMIN WEB ADMINISTRATION INTERFACE OTHERWISE IT WON'T BE APPLIED.

G.

Dear Greg,

 

We will be applying this tomorrow at the site. However  the customer who manages the database claims that this is not relevant.

 

The reason I am asking is , the customer claims that all the relevant fields in the transaction happens to get duly filled. It is only the .wav file that is not getting uploaded.

 

Could you just help me as what should I be telling him. I am also taking with me a person who is familiar with Java Script also.

Regards

 

Hi,

I am not sure the customer is on the right frequency.

Actually, there are multiple database operations in your script, and multiple tables involved. It just so happens that one table is updated and the other table is not.

For example, this SQL query (which inserts a row into the QUERY table) goes through (again, this would fail too, if the telco provider sends a non-numeric CLID):

insert into QUERY(QUERYID, QUERYDATE, QUERYSTATUSID, CATEGORYID, LANGUAGEID, IVRREFID, CALLERPHONENO) values( (select nvl(max(QUERYID),999)+1 from QUERY), SYSDATE, $bdQueryStatusId, $bdCategoryId, $bdLanguageId, $strIvrRefId, $intClid)

And this is the SQL command used to "upload" the recording (temporarily stored as docRecordedQuery (the result of the Recording step)  into the QUERYREPLYMEDIA table. And it fails - due to the misformatted Date (I posted the solution above):

insert into QUERYREPLYMEDIA(QUERYREPLYMEDIAID, QUERYREPLYFLAG, QUERYREPLYID, MEDIATYPEID, MEDIADATA, MEDIALASTUPATED) values((select nvl(max(QUERYREPLYMEDIAID),0)+1 from QUERYREPLYMEDIA), $bdQueryReplyFlag, $bdQueryId, $bdMediaTypeId, $docRecordedQuery, to_date($strToday_Date, 'dd-mon-yyyy'))

One more thing: JavaScript won't help too much. UCCX scripts use pure Java (JDK 6). Java and JavaScript are two completely different things.

G.

Dear  Greg,

 

Any reason then why is it working in CRA 3.5 with Oracle 9.1

 

Our new version is UCCX 9.0.1 with Oracle 9.1

 

Regards