I've implemented a Service component, and during initialization, it
calls on some hibernate classes. As hibernate starts, it grabs a
Configuration. During the Configuration initialization, Configuration
calls Thread.currentThread().getContextClassLoader().stuff.
The problem is that EAServer returns null from the
getContextClassLoader() call. More research indicated that EAServer is
allowed to return null if the class loader is the bootstrap class loader.
How can I convince EAServer (4.2.2) to utilize a different class loader?
Jeff...
Dave Wolf
Cynergy Systems
http://www.cynergysystems.com
"Jeffrey Voight" <jeff....@sybase.com> wrote in message
news:417d01f5@forums-1-dub...
Now, I'm up against a different hurdle: How to get hibernate
to perform the jndi lookup of the datasource. It seems to
fail. I'd like to be able to tell you the exception, but
instead, I get the '.... 9 more' message. I guess that's to
save my eyes from the horror that might be lurking there.
The final exception is a ClassCastException but I suspect
that it's actually failing the JNDI lookup instead.
In hibernate.cfg.xml, I'm limitted to a single line
connection lookup thingbob. I can't tell it my
jagadmin/passwd, give it odd contexts, or any of the stuff
that I'd normally use to start troubleshooting. Instead,
all we get is a line where we can put
java:comp/env/jdbc/connName. I'm using a copy of a
hibernate.cfg.xml that works in WebApplications, but since
I'm running my portion as a service, am I coming up against
restrictions placed there on purpose?
Also, any idea how to convince jaguar to not truncate the
exceptions?
Jeff...
You can unwind the stack yourself pretty easily. See
http://java.sun.com/j2se/1.4.2/docs/api/java/lang/Throwable.html#getStackTrace()
My guess would be it is expecting a DataSource and getting a Connection
or vice versa.
Dave Wolf
Cynergy Systems
http://www.cynergysystems.com
What I have found in the past is that sometimes instead of throwing an
exception to say it doesnt exist it returns a NamingContext object so
when you try to cast it as a DataSource it cant.
Pete
2. Before applying fixed as mentioned in step 1, I got rid
of exception by upzipping all hibernate classes and jarring
them with my EJB jar itself.
Thanks
Kishori