Bug 743437
Summary: | [jboss-as-5] type-mapping value for datasources is hard-coded in plug-in descriptor resulting in unsupported datasource resource configuration in RHQ | ||
---|---|---|---|
Product: | [Other] RHQ Project | Reporter: | Larry O'Leary <loleary> |
Component: | Plugins | Assignee: | Stefan Negrea <snegrea> |
Status: | CLOSED CURRENTRELEASE | QA Contact: | Mike Foley <mfoley> |
Severity: | high | Docs Contact: | |
Priority: | high | ||
Version: | 4.2 | CC: | hrupp, ian.springer, snegrea |
Target Milestone: | --- | ||
Target Release: | JON 3.0.0, RHQ 4.3.0 | ||
Hardware: | All | ||
OS: | All | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | Type: | --- | |
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: | 745494 |
Description
Larry O'Leary
2011-10-04 22:52:35 UTC
Making the type mappings dynamic is beyond the scope of JON3.0 We should look to determine how much effort, and any backward compatibility issues for existing resources in inventory there might be, to solve this by turning the field into which accepts free form text. This change should also not impose any burden on users creating new Datasources, they shouldn't have to type this info in. The reported problem does not affect JBoss AS4 plugin; Type Mapping property for that plugin is a text field. This BZ is applicable only to JBoss AS5 plugin. There are two instances where the Type Mapping occurs; Advanced -> Metadata -> Type Mapping and Advanced -> Type Mapping. The best solution to fix this issue is to dynamically generate the list of options from the conf file. However, as a downside the file would need to be scanned frequently to pick up changes made outside of RHQ. There is no support for this kind of functionality in RHQ right now. The second best solution is to have a set of predefined options and to allow users to add custom values to that list. However, the implementation is quiet complex because lack of support in the current domain and UI implementation (... and parsing of plugin descriptors). The third solution would be to transform the field into a text box. This is the only option available today. I updated the code to display a textbox for Type Mapping configuration. The field will be pre-populated by the plugin on a best effort case. Afterwards, the textbox will accept any value so the user can update to the desired value. Now that the field is a regular text box and allows any value, we ideally should do validation of the value in the plugin's impl of updateResourceConfiguration() and set an error on the PropertySimple if it's not a valid type mapping name. We'd have to see if it's possible to retrieve the list of valid type mapping names from the profile service. If so, this would be a fairly easy change. If not, and we had to use JMX or manual XML file access, it could be more involved. I added the list of default type mappings in the description of the property. The users can now just copy and paste any of the values that get distributed with AS5. Created BZ 752431 to implement type mapping validation. This BZ is ready for testing. https://bugzilla.redhat.com/show_bug.cgi?id=752431 master commits: http://git.fedorahosted.org/git/?p=rhq/rhq.git;a=commit;h=43566de98d044de20f96107c54d881e9144cfd2f http://git.fedorahosted.org/git?p=rhq/rhq.git;a=commit;h=7d6daf24fd744c8c3e513efaaa03a35c9f554c61 release_jon3.x commits: http://git.fedorahosted.org/git?p=rhq/rhq.git;a=commit;h=9939b5e91e46a78542b25b1650d898e042eee4fe http://git.fedorahosted.org/git?p=rhq/rhq.git;a=commit;h=1a8507f7efb36e4b6d018b18b4785e570a3e9a1f verified type mapping is a text box. marking VERIFIED JON 3 bugs to CLOSED/CURRENTRELEASE changing status of VERIFIED BZs for JON 2.4.2 and JON 3.0 to CLOSED/CURRENTRELEASE |