Bug 999056
| Summary: | Beaker adds empty params element to tasks | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Retired] Beaker | Reporter: | Nikolai Kondrashov <nikolai.kondrashov> | ||||
| Component: | general | Assignee: | Dan Callaghan <dcallagh> | ||||
| Status: | CLOSED CURRENTRELEASE | QA Contact: | tools-bugs <tools-bugs> | ||||
| Severity: | unspecified | Docs Contact: | |||||
| Priority: | unspecified | ||||||
| Version: | 0.14 | CC: | aigao, asaha, dcallagh, jingwang, kbanerje, llim, qwan, rmancy | ||||
| Target Milestone: | 0.16 | Keywords: | Patch | ||||
| Target Release: | --- | ||||||
| Hardware: | Unspecified | ||||||
| OS: | Unspecified | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | Doc Type: | Bug Fix | |||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2014-03-17 03:01:24 UTC | Type: | Bug | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Attachments: |
|
||||||
Created attachment 788553 [details]
0001-Don-t-add-empty-params-element.patch
Thanks for the patch - this probably won't make the next release (0.15), but we'll definitely aim to get it into 0.16 :) On Gerrit: http://gerrit.beaker-project.org/2770 verified on beaker-devel(build 0.15.4.git.110.c0912fb)-->pass
steps:
1. Submit a job containing empty "task" element, for examples:
<task name="/distribution/install" role="STANDALONE"/>
<task name="/xxx/xxx/xxx" role="STANDALONE"/>
<params>
</params>
<task name="/xxx/xxx/xxx/xxx" role="none"/>
<params/>
<task name="/distribution/reservesys" role="STANDALONE">
<params>
<param name="RESERVETIME" value="86400"/>
</params>
</task>
2. See XML generated when cloning the job.
Actual results:
same as Expected results.
Expected results:
<task name="/distribution/install" role="STANDALONE"/>
<task name="/xxx/xxx/xxx" role="STANDALONE"/>
<task name="/xxx/xxx/xxx/xxx" role="none"/>
<task name="/distribution/reservesys" role="STANDALONE">
<params>
<param name="RESERVETIME" value="86400"/>
</params>
</task>
Beaker 0.16.0 has been released. |
Description of problem: Jobs submitted via WebUI having "task" elements without parameters (no or empty "params" element) are then restored as having an empty "params" element, even though the schema specifies it as optional. This makes job XML unnecessarily longer and harder to read when there are many tasks without parameters. How reproducible: Always Steps to Reproduce: 1. Submit a job containing an empty "task" element, for example: <task name="/distribution/install" role="STANDALONE"/> 2. See XML generated when cloning the job. Actual results: <task name="/distribution/install" role="STANDALONE"> <params/> </task> Expected results: <task name="/distribution/install" role="STANDALONE"/> Additional info: Consider what a long list of such tasks becomes after submitting the job. For example, consider what Beaker would output when cloning this task list: <task name="/distribution/install" role="STANDALONE"/> <task name="/CoreOS/sssd/server_client/ds_setup/nkondras" role="CLIENT"/> <task name="/CoreOS/sssd/client/ldap_provider/ignore_group_members/nkondras" role="CLIENT"/> <task name="/CoreOS/sssd/client/ldap_provider/ignore_group_members/nkondras" role="CLIENT"/> <task name="/CoreOS/sssd/server_client/ds_teardown/nkondras" role="CLIENT"/> <task name="/CoreOS/sssd/server_client/ds_setup/nkondras" role="CLIENT"/> <task name="/CoreOS/sssd/client/ldap_provider/ignore_group_members/nkondras" role="CLIENT"/> <task name="/CoreOS/sssd/client/ldap_provider/ignore_group_members/nkondras" role="CLIENT"/> <task name="/CoreOS/sssd/server_client/ds_teardown/nkondras" role="CLIENT"/> The attached (untested) patch attempts to fix this.