
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-10-2022 11:42 AM
Hey everyone,
I have a CVP application that is doing a simple query per call to pull caller data. The solution is working as expected, however after a week or so (not the same time frame every occurrance) it will start erroring out and I see the following in the app ErrorLog:
The error was: A built-in element encountered an exception of type com.audium.server.AudiumException. Connection reset by peer: socket write error The root cause was: com.microsoft.sqlserver.jdbc.SQLServerException: Connection reset by peer: socket write error
I amended the CVP application to manually point to its backup database server in the event of a failure to the primary database, however I get an error stating it cannot bind the jdbc connection, although it exists in the context.xml file.
The error was: A built-in element encountered an exception of type com.audium.server.AudiumException. There was a problem looking up the JNDI data source 'gshbckp'. The root cause was: javax.naming.NameNotFoundException: Name [gshbckp] is not bound in this Context. Unable to find [gshbckp]. com.audium.server.AudiumException: A built-in element encountered an exception of type com.audium.server.AudiumException.
Restarting VXML services corrects this problem. I have reached out to TAC who is saying the issue is with the database while our database team is pointing to an application configuration issue. Below is the context.xml file:
<Resource auth="Container" name="jdbc/gsh" factory="org.apache.tomcat.jdbc.pool.DataSourceFactory" driverClassName="com.microsoft.sqlserver.jdbc.SQLServerDriver" url="jdbc:sqlserver://dbserver:1433;user=user;password=******;DatabaseName=DB" connection-creation-retry-attempts="5" type="javax.sql.DataSource" /> <Resource auth="Container" name="jdbc/gshbckp" factory="org.apache.tomcat.jdbc.pool.DataSourceFactory" driverClassName="com.microsoft.sqlserver.jdbc.SQLServerDriver" url="jdbc:sqlserver://dbserver2:1433;user=user;password=******;DatabaseName=DB" connection-creation-retry-attempts="5" type="javax.sql.DataSource" />
I am connecting to SQL Server 2019 standard with the mssql-jdbc-6.4.0.jre7.jar file.
Any assistance would be greatly appreciated.
Solved! Go to Solution.
- Labels:
-
CVP
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-10-2022 05:43 PM
former students had this issue many years ago and told me that the fix
was to remove the attribute named factory - it causes VXMLServer to NOT
re-connect after it loses connection to SQL.
I have this in my student guide:
*After 11.5: Do NOT use this factory method, as it causes VXML Server
not to reconnect if the SQL is restarted
factory="org.apache.tomcat.jdbc.pool.DataSourceFactory"*
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-10-2022 05:38 PM
Have you tried it at all without the 'connection-creation-retry-attempts="5"' section to see if you see any improvement/difference of opinion?
Also, what version of CVP is this?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-10-2022 05:43 PM
former students had this issue many years ago and told me that the fix
was to remove the attribute named factory - it causes VXMLServer to NOT
re-connect after it loses connection to SQL.
I have this in my student guide:
*After 11.5: Do NOT use this factory method, as it causes VXML Server
not to reconnect if the SQL is restarted
factory="org.apache.tomcat.jdbc.pool.DataSourceFactory"*
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-11-2022 08:51 AM
Hi @janinegraves , I'm guessing this is the defect you're mentioning?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-10-2025 08:47 AM
This solved my issue with SQL 2019 and CVP 12.6. Just to add, I just updated my vxml app using updateapp.sh script after modifying context.xml and that did apply the changes. I didnot restart VXML service, though i will do it during non working hours.
Thanks Janine, as always, you have been the savior when it comes to CVP VXML apps.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-10-2025 12:19 PM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-10-2022 06:24 PM
Thank you both for the reply. @bill.king1 I originally had that entry removed and added it to test. @janinegraves We are running CVP v11.6 currently and assumed your note was for v12+. I will remove that entry and give it another try.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-11-2022 06:43 AM

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-15-2022 07:06 AM
Closing the gap on this, Janine that worked. Turns out since I setup the SQL database as an availability group for redundancy, when the primary would failover, at times would cause the disconnect to the database. Removing the line from the context file worked. Thanks!

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2022 09:41 AM
Hello Chad, do you mind sharing an example of your XML file because I am getting an error that's strange for mine? Although I have multiple database types, the one I am truly trying to get to work is the MS SQL but i am getting the error "INVALID_CHARACTER_ERR: An invalid or illegal XML character is specified."
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2022 11:37 AM
Ahmed,
Can you please share your xml file with me and I can take a look. Also let me know which version of SQL/CVP you are using.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2022 12:03 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2022 01:55 PM
Ahmed, I assume you are seeing this as a java error in the application error logs? Tomcat doesn't like special characters so I am going on a limb here and saying the "@" in your password could potentially be hanging you up. You can either try escaping the character or omitting it entirely. I propose the latter to ensure connectivity.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2022 03:30 PM
Thank you Chad. I had also tried using a simple password as "password" and i am getting the same error.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
11-07-2022 04:08 PM
I removed the white space from my context.xml and replaced it with line-breaks (like yours) and got the same error as you 'invalid character in XML'.
So, I'm pretty sure that if you add a space between each attribute, like this - it'll fix your problem.
type="javax.sql.DataSource" DriverClassName="com.microsoft.sqlserver.jdbc.SQLServerDriver" url="jdbc:sqlserver://onl-mssql.voicelab.local:1433;DatabaseName=Cisco;user=sa;password=@DBAadmin;encrypt=true;trustServerCertificate=true"/>
