Bug 1057127 - jconsole doesn't work when patch upgrades some of its dependencies
Summary: jconsole doesn't work when patch upgrades some of its dependencies
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss Enterprise Application Platform 6
Classification: JBoss
Component: Scripts and Commands
Version: 6.2.1
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: DR0
: EAP 6.3.0
Assignee: Emanuel Muckenhuber
QA Contact: Petr Kremensky
Nidhi
URL:
Whiteboard:
Keywords:
Depends On:
Blocks: 1057501
TreeView+ depends on / blocked
 
Reported: 2014-01-23 13:45 UTC by Martin Simka
Modified: 2015-02-01 23:05 UTC (History)
10 users (show)

(edit)
Previous versions of JBoss EAP 6 contained a bug that prevented the jconsole.sh script from running whenever a CP1 patch was applied. The patch updated some hard-coded modules in jconsole.sh which, in turn, tampered the original module jar files. 

This meant that it was not possible to connect to an EAP console using jconsole.sh.

The issues was fixed by using the jboss-cli-client.jar from bin/client, which contains all required dependencies.
Clone Of:
: 1057501 (view as bug list)
(edit)
Last Closed: 2014-06-28 15:38:27 UTC


Attachments (Terms of Use)

Description Martin Simka 2014-01-23 13:45:45 UTC
Description of problem:
-----------------------
There is a hardcoded module path in jconsole.sh. When patch updates some module, original module jars are crippled and can't be used anymore.

Version-Release number of selected component (if applicable):
-----------------------
EAP 6.2.0 + patch which upgrades one of 
MODULES="org/jboss/remoting-jmx org/jboss/remoting3 org/jboss/logging org/jboss/xnio org/jboss/xnio/nio org/jboss/sasl org/jboss/marshalling org/jboss/marshalling/river org/jboss/as/cli org/jboss/staxmapper org/jboss/as/protocol org/jboss/dmr org/jboss/as/controller-client org/jboss/threads"

Steps to Reproduce:
-----------------------
1. start EAP
2. apply CP1 patch
3. restart EAP
3. start bin/jconsole.sh and try to connect to EAP process

Actual results:
-----------------------
Exception in thread "AWT-EventQueue-0" java.lang.NoClassDefFoundError: org/xnio/Option
	at org.jboss.remoting3.RemotingOptions.<clinit>(RemotingOptions.java:38)
	at org.jboss.as.cli.impl.CLIModelControllerClient.<clinit>(CLIModelControllerClient.java:65)
	at org.jboss.as.cli.impl.ModelControllerClientFactory$2.getClient(ModelControllerClientFactory.java:70)
	at org.jboss.as.cli.impl.CommandContextImpl.connectController(CommandContextImpl.java:806)
	at org.jboss.as.cli.gui.JConsoleCLIPlugin.connectUsingDefaults(JConsoleCLIPlugin.java:142)
	at org.jboss.as.cli.gui.JConsoleCLIPlugin.connectCommandContext(JConsoleCLIPlugin.java:102)
	at org.jboss.as.cli.gui.JConsoleCLIPlugin.getTabs(JConsoleCLIPlugin.java:77)
	at sun.tools.jconsole.VMPanel.createPluginTabs(VMPanel.java:668)
	at sun.tools.jconsole.VMPanel.propertyChange(VMPanel.java:334)
	at java.beans.PropertyChangeSupport.fire(PropertyChangeSupport.java:298)
	at java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:291)
	at javax.swing.event.SwingPropertyChangeSupport.firePropertyChange(SwingPropertyChangeSupport.java:92)
	at javax.swing.event.SwingPropertyChangeSupport$1.run(SwingPropertyChangeSupport.java:97)
	at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:226)
	at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:673)
	at java.awt.EventQueue.access$300(EventQueue.java:96)
	at java.awt.EventQueue$2.run(EventQueue.java:634)
	at java.awt.EventQueue$2.run(EventQueue.java:632)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:108)
	at java.awt.EventQueue.dispatchEvent(EventQueue.java:643)
	at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:275)
	at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:200)
	at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:190)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:185)
	at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:177)
	at java.awt.EventDispatchThread.run(EventDispatchThread.java:138)
Caused by: java.lang.ClassNotFoundException: org.xnio.Option
	at java.net.URLClassLoader$1.run(URLClassLoader.java:217)
	at java.security.AccessController.doPrivileged(Native Method)
	at java.net.URLClassLoader.findClass(URLClassLoader.java:205)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:321)
	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:294)
	at java.lang.ClassLoader.loadClass(ClassLoader.java:266)
	... 27 more


Additional info:
Correct module jars are loaded by jboss-modules. Script add-user.sh uses jboss-modules, perhaps jconsole.sh could use jboss-modules as well.

Comment 1 Emanuel Muckenhuber 2014-01-23 18:21:30 UTC
I opened a PR against 6.x: https://github.com/wildfly/wildfly/pull/5760

Comment 3 Martin Simka 2014-02-12 10:23:13 UTC
verified on EAP 6.3.0.DR0


Note You need to log in before you can comment on or make changes to this bug.