0

Class loader Exception

asked 2006-03-01 11:52:56 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3603969

By: matteo_barbieri

Hi, I have a problem and I don't know if it's caused by my application, ZK, Tomcat or MySQL.

When I use my application on a client, all works fine. But if I start another session on another client, it gives me this exception:

1-mar-2006 12.44.27 org.apache.catalina.loader.WebappClassLoader loadClass
INFO: Illegal access: this web application instance has been stopped already.
Could not load com.mysql.jdbc.Messages. The eventual following stack trace is caused by an error thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access, and has no functional impact.
java.lang.IllegalStateException
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoa
der.java:1238)
at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoa
der.java:1198)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
at com.mysql.jdbc.CommunicationsException.<init>(CommunicationsException
.java:174)
at com.mysql.jdbc.MysqlIO.send(MysqlIO.java:2710)
at com.mysql.jdbc.MysqlIO.send(MysqlIO.java:2621)
at com.mysql.jdbc.MysqlIO.quit(MysqlIO.java:1338)
at com.mysql.jdbc.Connection.realClose(Connection.java:4429)
at com.mysql.jdbc.Connection.cleanup(Connection.java:1973)
at com.mysql.jdbc.Connection.finalize(Connection.java:3114)
at java.lang.ref.Finalizer.invokeFinalizeMethod(Native Method)
at java.lang.ref.Finalizer.runFinalizer(Finalizer.java:83)
at java.lang.ref.Finalizer.access$100(Finalizer.java:14)
at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:160)


To make it work I have to reload the webapp with Tomcat.
I'm not a Tomcat expert, so maybe this error is caused by my configuration.

Could you give some advices?
Thanks.

delete flag offensive retag edit

16 Replies

Sort by ยป oldest newest

answered 2006-03-01 14:19:06 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3604762

By: tomyeh

According the stack trace, it looks like MySQL issue. Would you post this to their forum for real experty?

link publish delete flag offensive edit

answered 2006-03-01 14:21:36 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3604769

By: tomyeh

Hi Matteo,

I got no experience with MySQL (PostgreSQL is my favor). The stack trace looks odd to me: it looks like it is closing something (usually caused by recycle connections), but trying to load another class!

link publish delete flag offensive edit

answered 2006-03-01 14:47:49 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3604822

By: matteo_barbieri

There was another similar error before, maybe it's more important:

org.apache.catalina.loader.WebappClassLoader loadClass
INFO: Illegal access: this web application instance has been stopped already.
Could not load java.net.BindException. The eventual following stack trace is caused by an error thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access, and has no functional impact.
java.lang.IllegalStateException

That's why I don't think it's a MySQL error.

P.S. I would like to switch to PostgreSQL one day

link publish delete flag offensive edit

answered 2006-03-01 14:59:52 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3604847

By: tomyeh

There is one possibility. ZK starts an independent thread to handle event, so developer could suspend it without blocking the response.

On the other hand, some transaction manager uses ThreadLocale to store info.
It usually causes problem if you closes a transaction in a thread different from it is started.

Would you show me how you start and close the transaction?

link publish delete flag offensive edit

answered 2006-03-01 15:12:19 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3604875

By: matteo_barbieri

Hmm...
If you mean MySQL transactions I use Torque, so I don't manage transactions manually.
Now I verified that this error occours on the second client when I read the database.
I think I'll write also to the Torque mailing list.
Thank you

link publish delete flag offensive edit

answered 2006-03-03 14:32:53 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3608449

By: matteo_barbieri

No. :(
I've tried to ask to the Torque mailing list, but they think it's not a Torque problem.
Now I'm trying to investigate with Tomcat people, and I'm going to try with another application server.
It seems that the second browser uses the same MySQL connection of the first browser and that causes problems.
When I used php I hadn't this kind of problem, so maybe it could be even a problem with ZK, Torque and how they use thread or connections...
I don't know.

Thank you for interesting.

link publish delete flag offensive edit

answered 2006-03-03 14:49:28 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3608417

By: tomyeh

Hi Matteo,

Did you get the answer yet?

link publish delete flag offensive edit

answered 2006-03-03 15:46:31 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3608965

By: tomyeh

I'll look at it, too. But, I am occupied these days, so maybe some day next week -- hope so :)

link publish delete flag offensive edit

answered 2006-03-06 09:51:37 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3612726

By: matteo_barbieri

Nothing yet.
Asking around it seems it's a thread problem.
Maybe when I use a MySQL connection with ZK the connection remains active, and then creating another connection with another client, it throws this exception.
I don't know...

link publish delete flag offensive edit

answered 2006-03-06 14:26:29 +0800

admin gravatar image admin
18691 1 10 130
ZK Team


Orignial message at:
https://sourceforge.net/forum/message.php?msg_id=3613138

By: matteo_barbieri

Talking with some Tomcat guys, they say that I could try to stop threads with application listeners, because this could cause the problem.
Do you know what it means?
How does ZK stops threads?

link publish delete flag offensive edit
Your reply
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow

RSS

Stats

Asked: 2006-03-01 11:52:56 +0800

Seen: 410 times

Last updated: Apr 07 '06

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More