Bug 1389844 - Error "Configure either handover or exploded" when exploded="false" is used in combination with rhq:handover
Summary: Error "Configure either handover or exploded" when exploded="false" is used i...
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: JBoss Operations Network
Classification: JBoss
Component: Provisioning
Version: JON 3.3.7
Hardware: Unspecified
OS: Unspecified
unspecified
low
Target Milestone: ---
: JON 3.3.9
Assignee: Michael Burman
QA Contact: Mike Foley
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2016-10-28 21:38 UTC by Larry O'Leary
Modified: 2017-07-20 14:58 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2017-07-20 14:58:56 UTC
Type: Bug


Attachments (Terms of Use)

Description Larry O'Leary 2016-10-28 21:38:04 UTC
Description of problem:
Bundle subsystem fails to parse bundle's deploy.xml if the rhq:archive task defines its exploded attribute with a value of "false" and has a child task of rhq:handover.

Version-Release number of selected component (if applicable):
3.3.7

How reproducible:
Always

Steps to Reproduce:
1. From the Bundles select _New_.
2. In step 1 of _Bundle Creation Wizard_ select _Recipe_ radio-button.
3. Paste the following recipe:
+
----
<?xml version="1.0"?>
<project name="helloworld-war-bundle" default="main" xmlns:rhq="antlib:org.rhq.bundle">
  <rhq:bundle name="helloworld-war-bundle" version="1.0" description="A sample bundle containing the jboss-helloworld.war from EAP 6 quickstarts">
    <rhq:deployment-unit name="helloworld-war" compliance="filesAndDirectories">
      <rhq:archive name="jboss-helloworld.war" exploded="false">
        <rhq:handover action="deployment">
          <rhq:handover-param name="runtimeName" value="jboss-helloworld" />
        </rhq:handover>
      </rhq:archive>
    </rhq:deployment-unit>
  </rhq:bundle>
  <target name="main" />
</project>
----
4. Select _Next_.

Actual results:
Bundle creation fails with the error "[1477690572690] java.lang.Exception:Failed to parse the bundle Ant script. -> org.apache.tools.ant.BuildException:Configure either handover or exploded" and the following is logged to server log
----
    WARN  [org.rhq.coregui.server.gwt.BundleGWTServiceImpl] (http-/0.0.0.0:7080-5) Sending exception to client: [1477689980645] : java.lang.Exception: Failed to parse the bundle Ant script.
        at org.rhq.enterprise.server.plugins.ant.AntBundleServerPluginComponent.parseRecipe(AntBundleServerPluginComponent.java:137)
        at org.rhq.enterprise.server.plugin.pc.bundle.BundleServerPluginManager.parseRecipe(BundleServerPluginManager.java:158) [rhq-server.jar:4.12.0.JON330GA-redhat-2]
        at org.rhq.enterprise.server.bundle.BundleManagerBean.createBundleVersionViaRecipeImpl(BundleManagerBean.java:721) [rhq-server.jar:4.12.0.JON330GA-redhat-2]
        at org.rhq.enterprise.server.bundle.BundleManagerBean.createBundleVersionViaRecipe(BundleManagerBean.java:706) [rhq-server.jar:4.12.0.JON330GA-redhat-2]
        ...
        at org.rhq.enterprise.server.bundle.BundleManagerLocal$$$view80.createBundleVersionViaRecipe(Unknown Source) [rhq-server.jar:4.12.0.JON330GA-redhat-2]
        at org.rhq.coregui.server.gwt.BundleGWTServiceImpl.createBundleVersionViaRecipe(BundleGWTServiceImpl.java:95) [classes:]
        ...
    Caused by: Configure either handover or exploded
        at org.rhq.bundle.ant.type.ArchiveType.ensureHandoverOrExplodedIsConfigured(ArchiveType.java:106)
        at org.rhq.bundle.ant.type.ArchiveType.addConfigured(ArchiveType.java:90)
        ...
        at org.rhq.bundle.ant.AntLauncher.preconfigureTask(AntLauncher.java:325)
        at org.rhq.bundle.ant.AntLauncher.validateAndPreprocess(AntLauncher.java:278)
        at org.rhq.bundle.ant.AntLauncher.parseBundleDeployFile(AntLauncher.java:177)
        at org.rhq.enterprise.server.plugins.ant.AntBundleServerPluginComponent.parseRecipe(AntBundleServerPluginComponent.java:122)
        ... 105 more
----

Expected results:
No failure and bundle creation continues.

Additional info:
From the documentation, it indicates that exploded must be set to false. However, it appears that if the attribute exploded is set, regardless of value, bundle creation fails.


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