2 Replies Latest reply on Jul 23, 2014 10:57 AM by mazz

    RHQ agent compatibility? rhq-agent.supported.versions

    Elias Ross Master

      I noticed this feature 'rhq-agent.supported.versions' was added to 'master', but I can't access the Bugzilla on the details.


      It seems that adding a regex 'rhq-agent.supported.versions' to the server properties should allow a range (effectively) of agent versions to connect to RHQ server, but I'm not really aware of possible issues, say, having a 4.X connect to a 4.Y instance.

      Is it fairly likely that, say, RHQ 4.9 will work (say) with 4.12? I know a lot of work is done to track API changes, but what about wire/protocol changes?

        • 1. Re: RHQ agent compatibility? rhq-agent.supported.versions
          Elias Ross Master

          The way this works is to add to the ProductInfo.properties file on the server.


          vi ./modules/org/rhq/server-startup/main/deployments/rhq.ear/rhq-server.jar/org/rhq/enterprise/server/core/ProductInfo.properties
          # add supportedAgentVersions=.*
          rm jbossas/standalone/data/rhq-downloads/rhq-agent/rhq-server-agent-versions.properties # generated? needed?


          But the plugins, namely JBoss7 may not work on the agent side. For instance:


          2014-07-09 10:18:54,006 ERROR [main] (rhq.core.pc.plugin.PluginManager)- Plugin at [file:/Users/elias/workspace/rhq-agent/plugins/rhq-jboss-as-
          7-plugin-4.12.0-SNAPSHOT.jar] could not be loaded and will therefore not be deployed.
          org.rhq.core.clientapi.agent.PluginContainerException: Could not successfully parse the plugin descriptor [META-INF/rhq-plugin.xml]
          Caused by: org.rhq.core.util.exception.WrappedRemotingException: [Warning] cvc-complex-type.3.2.2: Attribute 'supportsMissingAvailabilityType' is not allowed to appear in element 'service'.


          Anyway, may work once I patch the plugin, but may not happen either.


          Update: Ran into serial incompatibility with ResourceType (increase in serial version number).


          10:32:55,751 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/jboss-remoting-servlet-invoker].[ServerInvokerServlet]]
           (http-/ JBWEB000236: Servlet.service() for servlet ServerInvokerServlet threw exception: java.io.InvalidClassException: org.rh
          q.core.domain.resource.ResourceType; local class incompatible: stream classdesc serialVersionUID = 3, local class serialVersionUID = 4
          1 of 1 people found this helpful
          • 2. Re: RHQ agent compatibility? rhq-agent.supported.versions
            mazz Master

            In the past, RHQ had what we called The Prime Directive, which meant that all servers could only talk to agents of the same version (and obviously, vice versa).

            The reason this new feature was added was because we wanted to be able to support patched agents which may still have the same major.minor version but could have different patch versions or build numbers. This will now allow us to, say, ship RHQ 4.13.GA, then ship a patch bringing the agent to RHQ 4.13.PATCH1 but still allowing that patched agent to talk to a RHQ 4.13.GA Server.


            The intention was not to support different major.minor versions. Merely to support patched agents or servers.  That isn't to say it couldn't be used to allow for that (in the future, today things will fail due to incompatibilities between major.minor versions), but that wasn't the initial intention - we'll still be releasing with those settings only allowing servers and agents to be the same major.minor version.