My Oracle Support Banner

java.lang.NoClassDefFoundError: org/apache/tomcat/dbcp/dbcp/BasicDataSourceFactory When Using JDBC with Tomcat (Doc ID 2448102.1)

Last updated on JANUARY 24, 2020

Applies to:

JDBC - Version 11.2.0.4.0 and later
Information in this document applies to any platform.

Symptoms

After performing a Tomcat/Java 6 to Tomcat/Java 8 upgrade, JDBC driver application fails to access Oracle database with:

java.lang.NoClassDefFoundError: org/apache/tomcat/dbcp/dbcp/BasicDataSourceFactory.
       at java.lang.ClassLoader.defineClass1(Native Method)
       at java.lang.ClassLoader.defineClass(ClassLoader.java:760)
       at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
       at java.net.URLClassLoader.defineClass(URLClassLoader.java:467)
       at java.net.URLClassLoader.access$100(URLClassLoader.java:73)
       at java.net.URLClassLoader$1.run(URLClassLoader.java:368)
       at java.net.URLClassLoader$1.run(URLClassLoader.java:362)
       at java.security.AccessController.doPrivileged(Native Method)
       at java.net.URLClassLoader.findClass(URLClassLoader.java:361)
       at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
       at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
       at java.lang.Class.forName0(Native Method)
       at java.lang.Class.forName(Class.java:348)
       at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1295)
       at org.apache.catalina.loader.WebappClassLoaderBase.loadClass(WebappClassLoaderBase.java:1137)
       at org.apache.naming.factory.FactoryBase.getObjectInstance(FactoryBase.java:61)
       at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:321)
       at org.apache.naming.NamingContext.lookup(NamingContext.java:839)
       at org.apache.naming.NamingContext.lookup(NamingContext.java:159)
       at org.apache.naming.NamingContext.lookup(NamingContext.java:827)
       at org.apache.naming.NamingContext.lookup(NamingContext.java:173)
       at org.apache.catalina.core.NamingContextListener.addResource(NamingContextListener.java:1015)
       at org.apache.catalina.core.NamingContextListener.createNamingContext(NamingContextListener.java:556)
       at org.apache.catalina.core.NamingContextListener.lifecycleEvent(NamingContextListener.java:252)
       at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94)
       at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5154)
       at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)



Changes

 

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Changes
Cause
Solution


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.