Brian Stansberry [
http://community.jboss.org/people/bstansberry%40jboss.com] created the
discussion
"Re: Embedded AS"
To view the discussion, visit:
http://community.jboss.org/message/571835#571835
--------------------------------------------------------------
Kabir Khan wrote:
I don't think you can change the classpath of an already running java program
No you can't. What that class was doing was an attempt to get the jboss-modules
SystemLocalLoader to not load undesired classes. It reads the java.class.path property
when determining what jars/directories to load from. That part actually seems to work.
The problem is the static intializer block in java.util.logging.LogManager tries to use
ClassLoader.getSystemClassLoader() to load the class. And that classloader's
unaffected by my change of the system property.
And that problem would affect your #2 solution as well. :( The true system classloader
is not controlled by jboss-modules, so any time some code uses it, it will see the
original classpath.
Do you know how the Arquillian guys are dealing with this problem?
--------------------------------------------------------------
Reply to this message by going to Community
[
http://community.jboss.org/message/571835#571835]
Start a new discussion in JBoss AS7 Development at Community
[
http://community.jboss.org/choose-container!input.jspa?contentType=1&...]