cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
785
Views
0
Helpful
0
Comments
cdnadmin
Community Member
This document was generated from CDN thread

Created by: Justine Joubran on 06-07-2011 10:51:03 AM
 
Hello,
 
I have a CVP application (version 😎 that contains several Database Elements. 
- Calling the first DB element is working and returning results correctly
- However, calling the secong DB element in the flow is returning the below exception (taken from the Error Logs) and the message "I'm sorry we are experiencing..." is heard:
The error was: Another thread is currently working on this session.  This means the original thread took too long to complete what it was doing.  To prevent abnormal behaviour the original thread will exit immediately.  The call should not be affected.
com.audium.server.MultipleThreadException: Another thread is currently working on this session.  This means the original thread took too long to complete what it was doing.  To prevent abnormal behaviour the original thread will exit immediately.  The call should not be affected.
 
Looking at the Activity Logs, there's an "error.badfetch"
 
Any idea what could be the problem?
 
Thanks in advance,
Justine.
 

Subject: RE: New Message from Justine Joubran in Customer Voice Portal (CVP) - CVP -
Replied by: GEOFFREY THOMPSON on 06-07-2011 10:56:41 AM
How big is the thread pool in the JNDI settings?

Regards,
Geoff

Subject: Re: New Message from Justine Joubran in Customer Voice Portal (CVP) - CVP -
Replied by: Janine Graves on 06-07-2011 11:01:41 AM
I've never seen this with multiple DB elements in one phone call/Studio
app in CVP 8.
How did you configure the context.xml file to use with this DB? Can you
copy/paste it into a post?
Are you trying to access different JNDI-named DBs?
What sort of DB is it?
What query does the first/second DB element make?

Janine


On 7/6/2011 10:51 AM, Cisco Developer Community Forums wrote:
> Justine Joubran has created a new message in the forum "CVP - All
> Versions":
>
> --------------------------------------------------------------
> Â
> Hello,
> Â
> I have a CVP application (version 😎 that contains several Database
> Elements.Â
> - Calling the first DB element is working and returning results correctly
> - However, calling the secong DB element in the flow is returning the
> below exception (taken from the Error Logs) and the message "I'm sorry
> we are experiencing..." is heard:
> /The error was: Another thread is currently working on this session.
> Â This means the original thread took too long to complete what it was
> doing. Â To prevent abnormal behaviour the original thread will exit
> immediately. Â The call should not be affected./
> /com.audium.server.MultipleThreadException: Another thread is
> currently working on this session. Â This means the original thread
> took too long to complete what it was doing. Â To prevent abnormal
> behaviour the original thread will exit immediately. Â The call should
> not be affected./
> Â
> Looking at the Activity Logs, there's an "error.badfetch"
> Â
> Any idea what could be the problem?
> Â
> Thanks in advance,
> Justine.
> Â
> --
> To respond to this post, please click the following link:
>
> <http://developer.cisco.com/web/cvp/forums/-/message_boards/view_message/4175097>
>
> or simply reply to this email.

--
Janine Graves

Subject: RE: New Message from Justine Joubran in Customer Voice Portal (CVP) - CVP -
Replied by: Justine Joubran on 06-07-2011 11:33:47 AM
How big is the thread pool in the JNDI settings?



 
Where do I search for this setting? Is it from CVP side or from the Database side?
Thanks,
Justine,

Subject: RE: Re: New Message from Justine Joubran in Customer Voice Portal (CVP) - C
Replied by: Justine Joubran on 06-07-2011 11:51:36 AM
Hi Janine,
 
1) context.xml file:
 
<!-- The contents of this file will be loaded for each web application -->
<Context>
    <!-- Default set of monitored resources -->
    <WatchedResource>WEB-INF/web.xml</WatchedResource>
    <Manager pathname="" />
   </Context>
 
 
2) Both DB elements have the same configuration (Type - JNDI Name)
 
3) it is an SQL database

 

4) SQL queries are the same with the difference of the WHERE condition.
First SQL query:
 select column1, column2, ..., column16  
 from table_name 
 where phone='{Data.Element.phoneTrim.phoneNumber}'
 
Second SQL query:
 select column1, column2, ..., column16  
 from table_name 
 where dknumber='{Data.Session.DKvalue}'




Thanks,
Justine.

Subject: RE: New Message from Justine Joubran in Customer Voice Portal (CVP) - CVP -
Replied by: GEOFFREY THOMPSON on 06-07-2011 12:05:41 PM
Janine meant server.xml where the JNDI expression is set.

When you say ¿SQL database¿ I suppose you mean a ¿Microsoft SQL Server¿ database. True?

Regards,
Geoff

Subject: RE: New Message from Justine Joubran in Customer Voice Portal (CVP) - CVP -
Replied by: Amlan Das on 06-07-2011 04:52:14 PM
You have set maxwait="1000".
This seems a little short if your DB is located in a different network. DB operations over different networks can be time consuming.
Try setting it to a larger value (eg. "5000" or "10000"); and see if this works.

Subject: RE: New Message from Justine Joubran in Customer Voice Portal (CVP) - CVP -
Replied by: GEOFFREY THOMPSON on 06-07-2011 04:54:57 PM
<Resource name="jdbc/DBConnection"
auth="Container"
type="javax.sql.DataSource"
removeAbandoned="true"
removeAbandonedTimeout="60"
logAbandoned="true"
validationQuery="SELECT 1"
factory="org.apache.tomcat.dbcp.dbcp.BasicDataSourceFactory"
driverClassName="com.microsoft.sqlserver.jdbc.SQLServerDriver"
url="jdbc:sqlserver://16.91.120.157:1433;user=XXX;password=YYY;DatabaseName=ZZZ"
/>


Justine,

Are you talking to a Microsoft SQL Server? If so, I¿d use the native driver in preference to the ODBC translation layer.

Regards,
Geoff
--------------------------------------------------------------------
Geoff Thompson            Unified Contact Center Practice
Email:  [email protected]<mailto:[email protected]>      HP Technology Consulting
Phone:  +1.408.447.4297   Hewlett-Packard Company
Mobile: +1.408.204.5297   19111 Pruneridge Ave, Cupertino, CA 95014
____________________________________________________________________

Subject: RE: New Message from Justine Joubran in Customer Voice Portal (CVP) - CVP -
Replied by: Justine Joubran on 06-07-2011 04:22:24 PM
server.xml file:

<Context path="/CVP">
<Resource name="jdbc/SQL"
auth="Container"
type="javax.sql.DataSource"
maxActive="200"
maxIdle="10"
maxwait="1000"
factory="org.apache.tomcat.dbcp.dbcp.BasicDataSourceFactory"
driverClassName="sun.jdbc.odbc.JdbcOdbcDriver"
url="jdbc:odbc:SQL"
username="123"
password="123"/>
</Context>

Subject: Re: New Message from Justine Joubran in Customer Voice Portal (CVP) - CVP -
Replied by: Janine Graves on 06-07-2011 04:40:57 PM
MaxWait is the number MILLISECONDS Tomcat waits for a connection to be
returned to the pool when there are no available connections before
throwing an exception. Perhaps you want to increase it to 5000.

Also, you might want to add these
removeAbandoned=¿true¿
removeAbandonedTimeout=¿600¿ (If a connection isn't returned to the pool
by the app after this many SECONDS, tomcat will 'abandon' the connection,
thus returning it to the pool)

Janine



On 7/6/2011 4:22 PM, Cisco Developer Community Forums wrote:
> Justine Joubran has created a new message in the forum "CVP - All
> Versions":
>
> --------------------------------------------------------------
> _server.xml file:_
>
> <Context path="/CVP">
> <Resource name="jdbc/SQL"
> auth="Container"
> type="javax.sql.DataSource"
> maxActive="200"
> maxIdle="10"
> maxwait="1000"
> factory="org.apache.tomcat.dbcp.dbcp.BasicDataSourceFactory"
> driverClassName="sun.jdbc.odbc.JdbcOdbcDriver"
> url="jdbc:odbc:SQL"
> username="123"
> password="123"/>
> </Context>
> --
> To respond to this post, please click the following link:
>
> <http://developer.cisco.com/web/cvp/forums/-/message_boards/view_message/4178680>
>
> or simply reply to this email.

--
Janine Graves
Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Quick Links