« Back to CVP - All Versions

Calling a jsp in CallStudio

Combination View Flat View Tree View
Threads [ Previous | Next ]
Hi all,
 
I want to call a jsp page that return me a value as below 1.
For this aim, i use a subdialog element in my Call Studio application, and give the URI that is not local.
That subdialogs vxml that i get from DebugLog as below 2.
 
When i run the app, I get “error.badfetch.http.404” error. But I can reach the http link in the vxml server browser.
 
So how can i call that jsp. Is there any other way than the subdialog element, or is the usage of subdialog element wrong?
 
1)
This is http://gbcallsteering-t.fw.garanti.com.tr/dialogs/Initialization.jsp
 
<?xml version="1.0"?>
<vxml version="2.0" xmlns="http://www.w3.org/2001/vxml">
            <%
                        String param1=request.getParameter("param1");
                        String param2=request.getParameter("param2");
                        String returnValue=param1+"|"+param2;
            %>
            <form id="main">
            <var name="returnValue" expr="'<%=returnValue%>'"/>
            <block>
                                   <return namelist="returnValue" />
            </block>
            </form>
</vxml>
 
 
2)
<?xml version="1.0" encoding="UTF-8"?>
<vxml xmlns="http://www.w3.org/2001/vxml" version="2.1" application="/CVP/Server?audium_root=true&amp;calling_into=IVR_DTMF_ASR_Sample&amp;session_id=10.231.16.145.1342789768788.1144.IVR_DTMF_ASR_Sample">
  <form id="audium_start_form">
    <block>
      <assign name="audium_vxmlLog" expr="''" />
      <goto next="#start" />
    </block>
  </form>
  <form id="start">
    <subdialog name="subdialog" src="http://gbcallsteering-t.fw.garanti.com.tr/dialogs/Initialization.jsp">
      <param name="Param1" value="3" />
      <param name="Param2" value="5" />
      <filled>
        <submit next="/CVP/Server" method="post" namelist="subdialog.Result audium_vxmlLog subdialog" />
      </filled>
    </subdialog>
  </form>
</vxml>
 
 
Thanks,
Deniz
 

I believe that with request.getParameter("param1") - you'll have to pass the data in the URI string, not as a VXML Parameter. So modify the URI line to this
http://gbcallsteering-t.fw.garanti.com.tr/dialogs/Initialization.jsp?param1=123&param2=456

Also - it's all case sensitive. So if the java is requesting lower-case 'param1' - then you'd better pass the data as lower case!

Janine

I tried as you said.
Now the vxml in debug log is as below:

But it doesnt work.

<?xml version="1.0" encoding="UTF-8"?>
<vxml xmlns="http://www.w3.org/2001/vxml" version="2.1" application="/CVP/Server?audium_root=true&amp;calling_into=IVR_DTMF_ASR_Sample&amp;session_id=10.231.16.145.1343114417796.1260.IVR_DTMF_ASR_Sample">
<form id="audium_start_form">
<block>
<assign name="audium_vxmlLog" expr="''" />
<goto next="#start" />
</block>
</form>
<form id="start">
<subdialog name="subdialog" src="http://gbcallsteering-t.fw.garanti.com.tr/dialogs/Initialization.jsp?param1=123&amp;param2=456">
<filled>
<submit next="/CVP/Server" method="post" namelist="audium_vxmlLog subdialog subdialog.returnValue" />
</filled>
</subdialog>
</form>
</vxml>

Can you provide the details on what error you are getting and/or post the activity log.
Hemal
________________________________
From: Cisco Developer Community Forums [cdicuser@developer.cisco.com]
Sent: Tuesday, July 24, 2012 2:36 AM
To: cdicuser@developer.cisco.com
Subject: New Message from deniz caglar in Customer Voice Portal (CVP) - CVP - All Versions: RE: Calling a jsp in CallStudio

deniz caglar has created a new message in the forum "CVP - All Versions":

--------------------------------------------------------------
I tried as you said.
Now the vxml in debug log is as below:

But it doesnt work.

<?xml version="1.0" encoding="UTF-8"?>
<vxml xmlns="http://www.w3.org/2001/vxml" version="2.1" application="/CVP/Server?audium_root=true&amp;calling_into=IVR_DTMF_ASR_Sample&amp;session_id=10.231.16.145.1343114417796.1260.IVR_DTMF_ASR_Sample">
<form id="audium_start_form">
<block>
<assign name="audium_vxmlLog" expr="''" />
<goto next="#start" />
</block>
</form>
<form id="start">
<subdialog name="subdialog" src="http://gbcallsteering-t.fw.garanti.com.tr/dialogs/Initialization.jsp?param1=123&amp;param2=456">
<filled>
<submit next="/CVP/Server" method="post" namelist="audium_vxmlLog subdialog subdialog.returnValue" />
</filled>
</subdialog>
</form>
</vxml>
--
To respond to this post, please click the following link:

<http://developer.cisco.com/web/cvp/forums/-/message_boards/view_message/6164866>

or simply reply to this email.

Is there a configuration or property to set in gateway or any other place? I havent done anything like that. Only i try to call jsp page with a subdialog invoke element. And i tested calling the page from vxml server via Internet Explorer, it was okey.

Activity Log:
Firstly, nothing writes to activity log, after timeout 2 minutes, the log content is here:

10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.430,,start,newcall,
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.430,,start,ani,888883454
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.430,,start,areacode,NA
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.430,,start,exchange,NA
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.430,,start,dnis,2525
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.430,,start,uui,NA
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.430,,start,iidigits,NA
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.430,,start,parameter,_ani=888883454
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.430,,start,parameter,CN=
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.430,,start,parameter,_dnis=2525
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.430,,start,parameter,callid=150319.462
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.430,,start,parameter,ANI=888883454
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.430,,start,parameter,STEP=
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.446,Welcome,enter,
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.450,Welcome,interaction,audio_group,initial_audio_group
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.649,Welcome,exit,done
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:46.649,Subdialog Invoke_02,enter,
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:49.493,Subdialog Invoke_02,element,error,error.badfetch.http.404
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:49.493,Subdialog Invoke_02,exit,
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:49.539,,element,error,error.badfetch.http.404
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:49.602,,element,error,error.badfetch.http.404
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:38:15.432,,element,warning,A session has timed out after 2 minutes. This is most likely caused by a start of call class or action element at the top of the callflow not completing before the voice browser's fetch timeout occurred. To resolve it ensure this class executes in a timely manner or run it in the background. Session timeouts may also occur under high load or if there are issues with a load balancer or voice browser.
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:38:15.432,,end,how,app_session_complete
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:38:15.432,,end,result,timeout
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:38:15.432,,end,duration,149

Error Log:
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:49.493,A VoiceXML error occurred of type "error.badfetch.http.404"
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:49.539,A VoiceXML error occurred of type "error.badfetch.http.404"
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:35:49.602,A VoiceXML error occurred of type "error.badfetch.http.404"
10.231.16.145.1343129746430.1309.IVR_DTMF_ASR_Sample,07/24/2012 14:38:15.432,A VoiceXML Session timeout occurred at element Subdialog Invoke_02: A session has timed out after 2 minutes. This is most likely caused by a start of call class or action element at the top of the callflow not completing before the voice browser's fetch timeout occurred. To resolve it ensure this class executes in a timely manner or run it in the background. Session timeouts may also occur under high load or if there are issues with a load balancer or voice browser.

Although I tried both of them and got the same error, i again want to ask if it is important calling jsp page via port 80 or 8080?

Deniz,
 
You didn't quite enter what I told you to use for the URI. You used ; where you need to use & between the parameters.
http://gbcallsteering-t.fw.garanti.com.tr/dialogs/Initialization.jsp?param1=123&param2=456
 
That'll solve one of your problems. Then make sure you can enter that same URI into a web-browser and see valid VXML code coming to the screen.
 
I was able to successfully test the jsp by putting it under VXMLServer/Tomcat/webapps/CVP and using this URL to access it
http://IP:7000/CVP/Initialization.jsp?param1=123&param2=456
 
I set the Subdialog_Invoke element's Settings as follows:
URI:http://IP:7000/CVP/Initialization.jsp?param1=123&param2=456
Local Application: false
Parameter: (leave blank)
Return Value: returnValue
 
And then I was able to log the element data {Data.Element.Subdialog_Invoke_01.returnValue}
 
 
 
 
 
 
 
 
 
 
 

Hi Janine,

The link string was correct, when i get the lines from log file, "&" character had changed to "&amp;", so it is ok.

As you said, i tried putting under wepsphere locally with ip address(not hostname), it worked.

We reliased that the problem is application can not solve the hostname. I tried putting it in to hosts file, and i tried reaching address from web browser, they were all okey. But when i tried from the application with host name, it doen't work. I can solve the problem by writing address with ip, but now I wonder why application cannot solve the hostname?

Thank,

Hi,

The problem was about not defining hostname in the VXML Gateway. I didnt know that the request goes to the target server from the VXML Gateway, so i only had done the hostname configuration in the vxml server. When i did it in the VXML Gateway, problem solved.

Thanks,
Deniz