title: Tomcat JNDI Resource - Class not found: oracle.jdbc.xa.client.OracleXADataSource
body: <p><strong>The Problem</strong></p>
  
  <p>Anytime I start my Tomcat server via Eclipse I always get a <strong>Class not found</strong> error:</p>
  
  <pre><code>SEVERE: Exception processing Global JNDI Resources
  javax.naming.NamingException: Class not found: oracle.jdbc.xa.client.OracleXADataSource
      at org.apache.naming.factory.BeanFactory.getObjectInstance(BeanFactory.java:136)
  </code></pre>
  
  <p><strong>The Setup</strong></p>
  
  <p>My <strong>server.xml</strong> file has a resource setup like:</p>
  
  <pre><code>&lt;GlobalNamingResources&gt;
      &lt;Resource name="sub1" auth="Container"
                type="oracle.jdbc.xa.client.OracleXADataSource"
                factory="org.apache.naming.factory.BeanFactory"
                user="****" password="*****"
                URL="**************************************" /&gt;
  &lt;/GlobalNamingResources&gt;
  </code></pre>
  
  <p><strong>context.xml</strong> has an entry that looks like so:</p>
  
  <pre><code>&lt;ResourceLink name="dataSource/sub1" global="sub1" type="javax.sql.DataSource" /&gt; 
  </code></pre>
  
  <p>On my application, I'm using Oracle's JDBC driver - <strong>classes12.jar</strong> </p>
  
  <p><strong>The Question</strong></p>
  
  <p>What do I need to fix on the Tomcat server so that it can find the appropriate class - <code>oracle.jdbc.xa.client.OracleXADataSource</code>.  My first guess would be that <strong>classes12.jar</strong> needs to be copied to a folder somewhere on the server.  I'm not even totally sure where the folder on Windows for Eclipse...  any help would be appreciated.</p>
  
  <p>Thanks!</p>