Bug 1129202
| Summary: | PGError when hostgroup name exceeds 245 characters | ||
|---|---|---|---|
| Product: | Red Hat Satellite | Reporter: | Sachin Ghai <sghai> |
| Component: | WebUI | Assignee: | orabin |
| WebUI sub component: | Foreman | QA Contact: | jcallaha |
| Status: | CLOSED ERRATA | Docs Contact: | |
| Severity: | medium | ||
| Priority: | low | CC: | dcleal, jcallaha, orabin |
| Version: | 6.0.4 | Keywords: | Triaged |
| Target Milestone: | Unspecified | ||
| Target Release: | Unused | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| URL: | http://projects.theforeman.org/issues/7038 | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2015-08-12 05:14:05 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: | 1120271 | ||
| Bug Blocks: | 1123818 | ||
Created redmine issue http://projects.theforeman.org/issues/7038 from this bug Moving to POST since upstream bug http://projects.theforeman.org/issues/7038 has been closed ------------- Ori Rabin Applied in changeset commit:5fbe760e04c27400c054c6260f6ffcfec72c2c8c. *** This bug is verified in upstream. This fix should eventually land in future downstream builds *** Version Tested: RHEL 65/66/7 ruby193-rubygem-foreman_hooks-0.3.7-2.el7.noarch foreman-postgresql-1.8.0-0.develop.201412040955git563fa28.el7.noarch qe-foreman-rhel7.usersys.redhat.com-qpid-client-cert-1.0-1.noarch foreman-libvirt-1.8.0-0.develop.201412040955git563fa28.el7.noarch ruby193-rubygem-foreman_bootdisk-4.0.2-1.el7.noarch foreman-compute-1.8.0-0.develop.201412040955git563fa28.el7.noarch ruby193-rubygem-foreman_discovery-1.4.1-1.el7.noarch foreman-proxy-1.8.0-0.develop.201411261259git6ddd00d.el7.noarch rubygem-hammer_cli_foreman_tasks-0.0.3-2.201409091410git163c264.git.0.988ca80.el7.noarch qe-foreman-rhel7.usersys.redhat.com-foreman-proxy-1.0-1.noarch foreman-release-1.8.0-0.develop.201412040955git563fa28.el7.noarch foreman-gce-1.8.0-0.develop.201412040955git563fa28.el7.noarch foreman-vmware-1.8.0-0.develop.201412040955git563fa28.el7.noarch rubygem-hammer_cli_foreman-0.1.3-1.201411121216git9381fc5.el7.noarch ruby193-rubygem-foreman-tasks-0.6.9-1.el7.noarch foreman-ovirt-1.8.0-0.develop.201412040955git563fa28.el7.noarch foreman-selinux-1.8.0-0.develop.201411281557gitf4a857f.el7.noarch foreman-1.8.0-0.develop.201412040955git563fa28.el7.noarch qe-foreman-rhel7.usersys.redhat.com-foreman-client-1.0-1.noarch qe-foreman-rhel7.usersys.redhat.com-apache-1.0-1.noarch qe-foreman-rhel7.usersys.redhat.com-parent-cert-1.0-1.noarch ruby193-rubygem-foreman_docker-0.2.0-2.el7.noarch qe-foreman-rhel7.usersys.redhat.com-puppet-client-1.0-1.noarch qe-foreman-rhel7.usersys.redhat.com-qpid-broker-1.0-1.noarch This bug is slated to be released with Satellite 6.1. 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://access.redhat.com/errata/RHSA-2015:1592 |
Description of problem: I was trying to validate the hostgroup form and found that if we enter more than 245 chars in 'Name' field of hostgroup, It raises PGError: -- Processing by HostgroupsController#update as HTML Parameters: {"utf8"=>"✓", "authenticity_token"=>"8YKMIr6xgzHyJpwH0LC3VbHzoQSwOk+VOG2XoH0FhiE=", "hostgroup"=>{"name"=>"SSTQOPqJiwFllLmBmDRZoWsarPNwQhcEypKFfTozMHnmPtTqkgebNCMSMxBdywiWmEbraUdMnjnSIvdKFeioxAgvPTutMitBTTRExegkJRTzxlAHDIasfjwEAabNhzvevKiTDbYXbaqVFArexnApWfavHFpPSoDothzHwKVZOYrqGtSicQxHHrBoLcuNwrANGduNLMCurtGjlrkweKZNVqDaxmOPfvHBQjwapFpfbhLxGPksMwxGn1", "environment_id"=>"", "content_source_id"=>"", "puppet_ca_proxy_id"=>"", "puppet_proxy_id"=>"", "domain_id"=>"", "realm_id"=>"", "architecture_id"=>"", "root_pass"=>"[FILTERED]", "location_ids"=>[""], "organization_ids"=>[""]}, "kt_environment_id"=>"", "kt_activation_keys"=>"", "commit"=>"Submit", "id"=>"16-sstqopqjiwflllmbmdrzowsarpnwqhceypkfftozmhnmpttqkgebncmsmxbdywiwmebraudmnjnsivdkfeioxagvptutmitbttrexegkjrtzxlahdiasfjweaabnhzvevkitdbyxbaqvfarexnapwfavhfppsodothzhwkvzoyrqgtsicqxhhrbolcunwrangdunlmcurtgjlrkwekznvqdaxmopfvhbqjwapfpfbhlxgpksmwxgn"} Operation FAILED: PGError: ERROR: value too long for type character varying(255) : UPDATE "lookup_values" SET "match" = 'hostgroup=SSTQOPqJiwFllLmBmDRZoWsarPNwQhcEypKFfTozMHnmPtTqkgebNCMSMxBdywiWmEbraUdMnjnSIvdKFeioxAgvPTutMitBTTRExegkJRTzxlAHDIasfjwEAabNhzvevKiTDbYXbaqVFArexnApWfavHFpPSoDothzHwKVZOYrqGtSicQxHHrBoLcuNwrANGduNLMCurtGjlrkweKZNVqDaxmOPfvHBQjwapFpfbhLxGPksMwxGn1' WHERE "lookup_values"."match" = 'hostgroup=SSTQOPqJiwFllLmBmDRZoWsarPNwQhcEypKFfTozMHnmPtTqkgebNCMSMxBdywiWmEbraUdMnjnSIvdKFeioxAgvPTutMitBTTRExegkJRTzxlAHDIasfjwEAabNhzvevKiTDbYXbaqVFArexnApWfavHFpPSoDothzHwKVZOYrqGtSicQxHHrBoLcuNwrANGduNLMCurtGjlrkweKZNVqDaxmOPfvHBQjwapFpfbhLxGPksMwxGn' Rendered common/500.html.erb within layouts/application (5.7ms) Rendered layouts/base.html.erb (1.4ms) Completed 500 Internal Server Error in 67ms (Views: 9.7ms | ActiveRecord: 8.1ms) --- Version-Release number of selected component (if applicable): sat6 GA snap4 How reproducible: always Steps to Reproduce: 1. create hostgroup with more than 245 char in name 2. 3. Actual results: Operation FAILED: PGError: ERROR: value too long for type character varying(255) Expected results: User should be allowed to enter 255 char in name field and if it exceeds 255 char then UI should throw a clean validation error instead of PGError Additional info: