1 Reply Latest reply on Feb 6, 2016 12:14 PM by Gareth Healy

    generic-plugin fails to install

    Gareth Healy Newbie

      I am trying to create a generic-plugin based on: https://github.com/rhq-project/rhq/tree/master/modules/enterprise/server/plugins/alertdef-rhq


      But when i deploy or try to validate with the rhq-plugin, it fails with:


      18:02:41,838 INFO  [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/coregui]] (http-/0.0.0.0:7080-3) org.rhq.coregui.CoreGUI PluginFileUploadServlet: file was uploaded: gah-alert-definitions-1.0.0-SNAPSHOT.jar

      18:02:41,841 INFO  [org.rhq.coregui.server.gwt.PluginFileUploadServlet] (http-/0.0.0.0:7080-3) A new plugin [gah-alert-definitions-1.0.0-SNAPSHOT.jar] has been uploaded to [/opt/rh/jon-server-3.3.0.GA/jbossas/standalone/tmp/upload_46010f9a_1523a6cdd79__7fff_00000004.tmp]

      18:02:41,844 INFO  [org.rhq.coregui.server.gwt.PluginFileUploadServlet] (http-/0.0.0.0:7080-3) A new plugin has been deployed [/opt/rh/jon-server-3.3.0.GA/plugins/gah-alert-definitions-1.0.0-SNAPSHOT.jar]. A scan is required now in order to register it.

      18:04:19,642 ERROR [org.rhq.core.clientapi.descriptor.AgentPluginDescriptorUtil] (EJB default - 10) Validation fatal error while parsing [gah-alert-definitions-1.0.0-SNAPSHOT.jar:META-INF/rhq-plugin.xml] at line 28, column 146: cvc-elt.1: Cannot find the declaration of element 'generic-plugin'.

      18:04:19,644 WARN  [org.rhq.enterprise.server.core.plugin.PluginDeploymentScanner] (EJB default - 10) Does not look like [/opt/rh/jon-server-3.3.0.GA/plugins/gah-alert-definitions-1.0.0-SNAPSHOT.jar.fixme] is a plugin jar -(Cause: java.lang.NullPointerException:no xml descriptor found in jar). It will be ignored. Please fix that file or remove it. Looking at other examples, i can't see whats wrong, since the element generic plugin seems valid.


      My code is @ https://github.com/garethahealy/jon-plugins/blob/master/gah-alert-definitions/src/main/resources/META-INF/rhq-plugin.xml


      Dev machine:localhost:gah-alert-definitions garethah$ mvn -version Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=512m; support was removed in 8.0 Apache Maven 3.2.3 (33f8c3e1027c3ddde99d3cdebad2656a31e8fdf4; 2014-08-11T21:58:10+01:00) Maven home: /Users/garethah/Documents/dev/utils/apache-maven-3.2.3 Java version: 1.8.0_65, vendor: Oracle Corporation Java home: /Library/Java/JavaVirtualMachines/jdk1.8.0_65.jdk/Contents/Home/jre Default locale: en_US, platform encoding: UTF-8 OS name: "mac os x", version: "10.11.2", arch: "x86_64", family: "mac"


      JON is deployed within a vagrant image, running v3.3, with patch 4 and commons-collection security fix applied:[vagrant@jonserver logs]$ mvn -version Apache Maven 3.3.3 (7994120775791599e205a5524ec3e0dfe41d4a06; 2015-04-22T11:57:37+00:00) Maven home: /usr/share/apache-maven Java version: 1.8.0_65, vendor: Oracle Corporation Java home: /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.65-3.b17.el7.x86_64/jre Default locale: en_GB, platform encoding: UTF-8 OS name: "linux", version: "3.10.0-327.3.1.el7.x86_64", arch: "amd64", family: "unix"