This is a tracker issue for when we want to upgrade JBoss/Remoting that RHQ uses. AS7.1.1.Final (which is what RHQ 4.6 uses) and near term future releases of AS/EAP will be using Remoting 3.x. We should ultimately get on that.
I tried just upgrading to Remoting 2.5.4.SP4 (latest remoting 2 release) and hit a problem. See Ron Sigal's post here: https://community.jboss.org/message/304721#304721 where he states the ObjectName of the invoker is now customized based on host/port whereas before we could just hardcoded it in the web.xml. But we can't know what host/port the installer of RHQ will use so we can't hardcode it here. Not sure how to fix this.
as an example of the new ObjectName, here's what I see in JConsole connected to my RHQ Server that is running remoting 2.5.4 - the ObjectName is jboss.remoting:service=invoker,transport=servlet,host=mazztower,port=7080,rhq.communications.connector.rhqtype=server before, in remoting 2.2, it was just jboss.remoting:service=invoker,transport=servlet
In the new remoting 2.5.4, here's the new code that builds and uses the new ObjectName: org.jboss.remoting.transport.Connector.init() final ObjectName objName = new ObjectName(invoker.getMBeanObjectName()); ... if (!server.isRegistered(objName)) { server.registerMBean(invoker, objName); } The method org.jboss.remoting.getMBeanObjectName() builds and returns the new ObjectName
I've got this working but I had to create our own subclass of JBoss/Remoting's ServletInvokerServlet so we can find the MBean. All unit tests and integration tests pass successfully. I ran server and agent (once with server using servlet: protocol and agent using socket: protocol, and then with server using sslservlet: protocol and agent using sslsocket: protocol - all works). I also ran the CLI and it can connect and run successfully too.
git commit to master: b768148fd0db16a57616231b80963abebbce82ae I'm closing this issue - if we need to upgrade to Remoting 3 in the future, that's another issue that should be raised.