On 5/17/07, Molina, Teresa <[EMAIL PROTECTED]> wrote:
I've been trying to use Tomcat 6 (with Java 6) on FC6, but I cannot seem
to get the third-party transaction manager integrated as in previous
versions. I have configured everything just as in Tomcat 5.5, but there
seems to be a change in the classloading structure, which simply
prevents the classes from loading.

Originally, I had the all the necessary Objectweb (JOTM is my
transaction manager) in a directory outside of the CATALINA_BASE but had
appended them to the beginning of the classpath in setclasspath.sh,
which is how it currently works. With the failure to initialize, I moved
all needed jars into CATALINA_BASE/bin, after first trying
CATALINA_BASE/lib.

I don't know anything about Objectweb or JOTM transaction manager, but
just trying to point a few corrections with the configuration.

I think you should keep the JAR files in the lib folder and not the bin folder.

I did configure MySQL JDBC Datasource (for connection pooling)
successfully, so I have some basic idea about it how it is supposed to
be configured for Oracle and MySQL.

My suspicion is that there's a class that is needed
by the Objectweb DataSourceFactory that was previously included but is
no longer found, due to a change in the classloading architecture; but,
that's almost purely theoretical.

This is the error from catalina.out:

WARNING: Failed to register in JMX: javax.naming.NamingException: Could
not create resource factory instance [Root exception is
java.lang.NoClassDefFoundError: Could not initialize class
org.objectweb.jndi.DataSourceFactory]

I would try to connect directly without using JNDI first, to make sure
a direct connection works.

This is what's configured as a global resource in server.xml:
<Resource name="AdminCop"
                    min="1"
                    max="1"
                    auth="Container"
                    type="javax.sql.DataSource"
                    factory="org.objectweb.jndi.DataSourceFactory"
                   driverClassName="oracle.jdbc.driver.OracleDriver"
                    username="xxx"
                    password="xxx"
                    url="jdbc:oracle:thin:@localhost:xxxx:XXX" />


Where have you placed the above <Resource /> tag ?

It should be placed either inside your applications <Context node
(please note that it is possible that your Context node could be
defined outside server.xml, in that case you would place it where ever
the Context node is defined --- may be in server.xml or may be
outside)

, or in <GlobalNamingResources node.

I'm not sure if you can use min and max attributes above. I couldn't
find any attributes with those names here:
http://jakarta.apache.org/commons/dbcp/configuration.html

I have, of course, read the appropriate JNDI How-To, but, as I say, I
have configured all resources, properties, paths, etc, exactly the same
as in Tomcat 5.5 with no luck. Any help would be greatly appreciated.

Thanks!

-- Teresa


Regards
Rashmi

---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to