Bug 1184267
Summary: | catalogiteminitialization/catalogbundleinitialization methods cant parse tag control arrays | |||
---|---|---|---|---|
Product: | Red Hat CloudForms Management Engine | Reporter: | Josh Carter <jocarter> | |
Component: | Automate | Assignee: | Tina Fitzgerald <tfitzger> | |
Status: | CLOSED ERRATA | QA Contact: | Shveta <sshveta> | |
Severity: | high | Docs Contact: | ||
Priority: | medium | |||
Version: | 5.3.0 | CC: | gmccullo, jhardy, mfeifer, obarenbo, pmcgowan, sshveta, tfitzger, xlecauch | |
Target Milestone: | GA | |||
Target Release: | 5.4.0 | |||
Hardware: | All | |||
OS: | All | |||
Whiteboard: | ||||
Fixed In Version: | Doc Type: | Bug Fix | ||
Doc Text: | Story Points: | --- | ||
Clone Of: | ||||
: | 1225930 (view as bug list) | Environment: | ||
Last Closed: | 2015-06-16 12:48:06 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: | ||||
Bug Depends On: | ||||
Bug Blocks: | 1225930 |
Description
Josh Carter
2015-01-20 22:10:19 UTC
Tina - would you please provide a comment about why you moved this to POST? Is it a doc-only issue? Several other problems surfaced while testing the fix for this this issue. Kevin Morey had addressed some of those issues, so it made sense to upgrade and modify his latest versions of the catalogiteminitialization and catalogbundleinitialization automate methods. Since the majority of these 2 methods are consumed with parsing dialog information, and each differently, it made sense to separate the parsing into a separate method that would normalize the dialog information. As a result, what started as a fix for this issue resulted in added functionality that requires documentation changes. More detail can be found in the PR: https://github.com/ManageIQ/manageiq/pull/2479 Hi Shveta, First, you should create a service dialog: All dialog entries are automatically prefixed with "dialog_" so it is not necessary to add the dialog prefix when creating the service dialog attributes. The dialog processing is supposed to pass the correct information to the appropriate item(s). This is accomplished by the use of a naming and numbering schema. In addition to custom dialog names, attribute names containing "option" and "tag" could have special meaning. The dialog numbering schema is setup so dialog attributes with zero key entries are global and passed to all service items. The non-zero key entries are applied to the service items that have a matching provision index. Service item 1 will have options for 0 and 1, service item 2 will have options for 0 and 2, ….. The combination of naming(options and tags) and numbering(global vs item specific) is key to setting up the dialog attributes: I would setup something like this: tag_0_attr1 <---- use tagcontrol - make multiselect like department option_0_attr2 <---- contents unimportant - text box is fine tag_1_attr3 <---- use tagcontrol - make single value like location option_1_attr4 <---- contents unimportant - text box is fine tag_2_attr5 <---- contents unimportant - text box is fine option_2_attr6 <---- contents unimportant - text box is fine tag_3_attr7 <---- contents unimportant - text box is fine option_3_attr8 <---- contents unimportant - text box is fine plus 3 special attributes: service_name <---- to override service name service_description <---- to override service description vm_name or target_name <---- to override the vm name Once the dialog is created, Create 3 service catalog items(provider type doesn't matter), specify: * display in catalog * Provisioning entrypoint of /Service/Provisioning/Statemachines/ServiceProvision_Template/Catalogiteminitialization Create a service bundle * display in catalog * containing the 3 items above * Provisioning entrypoint of /Service/Provisioning/Statemachines/ServiceProvision_Template/Catalogbundleinitialization Important - Specify the provision order for 3 items. This is the value that is going to match the dialog number scheme described above. Edit /Service/Provisioning/Statemachines/ServiceProvision_Template/Catalogbundleinitialization instance move this: /Service/Provisioning/StateMachines/Methods/CatalogBundleInitialization to pre2 slot add this to pre1 slot /Service/Provisioning/StateMachines/Methods/DialogParser Edit /Service/Provisioning/Statemachines/ServiceProvision_Template/Catalogiteminitialization instance move this: /Service/Provisioning/StateMachines/Methods/CatalogItemInitialization to pre2 slot add this to pre1 slot /Service/Provisioning/StateMachines/Methods/DialogParser Finally, provision: catalog item and check results: catalog bundle and check results: *service_name should be named specified in dialog *service_description should be description specified in dialog *vm_name should be vm_name specified in dialog Check provisioned vm for tags specified and automation.log for further detail. Service name , description and vm name takes the values passed in dialog fields. verified in 5.4.0.0.24.20150427192818_1fd9e49 Cloned to documentation based on Tina's comments. Setting requires_doc_text -. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHBA-2015-1100.html |