[jboss-user] [Messaging, JMS & JBossMQ] - Re: No ClassLoaders found for: ClassLoading problem in JMS M

adrian@jboss.org do-not-reply at jboss.com
Thu Jul 12 11:42:47 EDT 2007

"avis1977" wrote : Thats correct... we are infact using the defineClass()
  | That's not surprising since there is no other way to load a class.
  | Is there a way still to make this class available to the RepositotyClass loader.

Yes. As long as you haven't already tried to load the class,
otherwise it will cache the miss and tell you the forever the class could not be

anonymous wrote : 
  | By the way the classLoader instance that I get at the point of time when I generate my code is an instance of the GenericClassLoader.

That's not a JBoss classloader of any type. I can't even tell you whose it is

The information doesn't make your question any more answerable than it was originally.
It's just some debug code for which you don't show any output or where
it is being executed.

Let me make some observations (I'm leaving this thread now).


2) If you are going to play with classloaders then you need to understand how
they work. 
In particular the JBoss classloading structure, i.e. what is visible from what context
e.g. each ejb gets its own thread context classloader (even if they share
the same underlying parent classloader)

3) What you are doing won't even work if you enable the java security manager.

4) If you really want your question answered (when you post it in a forum
that is relevant) then you need to post pertinent information.

e.g. I've yet to see the code that actually defines the class, where that is done
against which classloader, etc.

When I say which classloader, I mean classloader.toString() and
a print of the classloader.getParent() stack, NOT some code doing

  | Thread.currentThread.getContextClassLoader()
which it meaningless since it could have any value depending upon where your code executes.

The list of what is required for somebody to understand your question 
is longer than this, you can find it on the WIKI.
I'm certainly not going to go through 20 posts to try to squeeze that information out of you.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4063588#4063588

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4063588

More information about the jboss-user mailing list