Bug 1125831
Summary: | PGError: ERROR: bigint out of range: on setting entries_per_page to long integer value | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Product: | Red Hat Satellite | Reporter: | Sachin Ghai <sghai> | ||||||||
Component: | WebUI | Assignee: | orabin | ||||||||
WebUI sub component: | Foreman | QA Contact: | Tazim Kolhar <tkolhar> | ||||||||
Status: | CLOSED ERRATA | Docs Contact: | |||||||||
Severity: | medium | ||||||||||
Priority: | low | CC: | cwelton, dcleal, tkolhar | ||||||||
Version: | 6.0.4 | Keywords: | Triaged | ||||||||
Target Milestone: | Unspecified | ||||||||||
Target Release: | Unused | ||||||||||
Hardware: | Unspecified | ||||||||||
OS: | Unspecified | ||||||||||
URL: | http://projects.theforeman.org/issues/6874 | ||||||||||
Whiteboard: | |||||||||||
Fixed In Version: | Doc Type: | Bug Fix | |||||||||
Doc Text: | Story Points: | --- | |||||||||
Clone Of: | Environment: | ||||||||||
Last Closed: | 2015-08-12 05:12:31 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 923128 [details]
UI shows long numerid value for param "entries_per_page"
Created redmine issue http://projects.theforeman.org/issues/6874 from this bug Please note that there are other parameters under general tab, like "idle_timeout", "max_trend". we should define higher limits of these parameters too. As of now I can define any numeric value for these parameters. idle_timeout shouldn't be a problem, it was fixed in bug #1113349. If there are different issues with extreme values of those settings, new BZs would be best as they're not really related. (In reply to Dominic Cleal from comment #4) > idle_timeout shouldn't be a problem, it was fixed in bug #1113349. I can still set long integer value for idle_timeout though I didn't see any error or issue after setting it. But it would be good if we can set certain limit for such parameters. > If there > are different issues with extreme values of those settings, new BZs would be > best as they're not really related. Sure. thank you. (In reply to Sachin Ghai from comment #5) > > > (In reply to Dominic Cleal from comment #4) > > idle_timeout shouldn't be a problem, it was fixed in bug #1113349. > > I can still set long integer value for idle_timeout though I didn't see any > error or issue after setting it. But it would be good if we can set certain > limit for such parameters. If it doesn't cause any problems, I don't think there's a reason to limit it. The bug was easily fixed, but I'm sure a limit would have been introduced if necessary. It might be this setting will get a limit to fix the bug you found. Upstream bug assigned to orabin Moving to POST since upstream bug http://projects.theforeman.org/issues/6874 has been closed ------------- Ori Rabin Applied in changeset commit:c737b10e70187bfeeb0727edc2282f25cf7165e4. VERIFIED: *** This bug is verified in upstream. This fix should eventually land in future downstream builds *** # rpm -q | grep foreman rpm: no arguments given for query [root@qe-foreman-rhel66 ~]# rpm -qa | grep foreman foreman-ovirt-1.8.0-0.develop.201412111740git287d974.el6.noarch qe-foreman-rhel66.usersys.redhat.com-puppet-client-1.0-1.noarch foreman-gce-1.8.0-0.develop.201412111740git287d974.el6.noarch ruby193-rubygem-foreman-tasks-0.6.10-2.el6.noarch rubygem-hammer_cli_foreman-0.1.4-1.201412111235git2131f5d.el6.noarch foreman-release-1.8.0-0.develop.201412111740git287d974.el6.noarch qe-foreman-rhel66.usersys.redhat.com-foreman-client-1.0-1.noarch qe-foreman-rhel66.usersys.redhat.com-qpid-client-cert-1.0-1.noarch ruby193-rubygem-foreman_docker-0.2.0-2.el6.noarch ruby193-rubygem-foreman_discovery-1.4.1-1.el6.noarch ruby193-rubygem-foreman_bootdisk-4.0.2-1.el6.noarch foreman-libvirt-1.8.0-0.develop.201412111740git287d974.el6.noarch qe-foreman-rhel66.usersys.redhat.com-apache-1.0-1.noarch qe-foreman-rhel66.usersys.redhat.com-parent-cert-1.0-1.noarch foreman-1.8.0-0.develop.201412111740git287d974.el6.noarch foreman-vmware-1.8.0-0.develop.201412111740git287d974.el6.noarch foreman-selinux-1.8.0-0.develop.201411281557gitf4a857f.el6.noarch foreman-proxy-1.8.0-0.develop.201412111700gita7c8c34.el6.noarch foreman-postgresql-1.8.0-0.develop.201412111740git287d974.el6.noarch qe-foreman-rhel66.usersys.redhat.com-foreman-proxy-1.0-1.noarch qe-foreman-rhel66.usersys.redhat.com-qpid-broker-1.0-1.noarch foreman-compute-1.8.0-0.develop.201412111740git287d974.el6.noarch ruby193-rubygem-foreman_hooks-0.3.7-2.el6.noarch rubygem-hammer_cli_foreman_tasks-0.0.3-2.201409091410gitc96619d.git.0.37f3704.el6.noarch UI does not allow to set long integer value under settings --> general --> select "entries_per_page" screen shot attached Created attachment 967624 [details]
entries per page value
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 |
Created attachment 923127 [details] ERROR: bigint out of range on setting parameter with long interger value Description of problem: while performing boundary tests, I tried to set the "entries_per_page" parameter value with long integer value and on save, it was set as some exponential value. but when I navigate to some other tab and get back, the value was displayed correctly. Later when I navigate to other page(for example: users), UI throws following error: -- Oops, we're sorry but something went wrong Error PGError: ERROR: bigint out of range : SELECT "users".* FROM "users" WHERE (1=1) AND (users.auth_source_id <> 2) LIMIT 299999999999999999999999999999999999999999999999999999999999 OFFSET 0 --- Version-Release number of selected component (if applicable): sat6 GA snap1 How reproducible: always Steps to Reproduce: 1. Go to settings --> general --> select "entries_per_page" and update it with long integer value 2. 3. Actual results: Production.logs: when I navigate to 'users' menu: Processing by UsersController#index as HTML Rendered users/index.html.erb within layouts/application (7.4ms) Operation FAILED: PGError: ERROR: bigint out of range : SELECT "users".* FROM "users" WHERE (1=1) AND (users.auth_source_id <> 2) LIMIT 299999999999999999999999999999999999999999999999999999999999 OFFSET 0 Rendered common/500.html.erb within layouts/application (5.4ms) Rendered layouts/base.html.erb (1.2ms) Completed 500 Internal Server Error in 186ms (Views: 9.0ms | ActiveRecord: 0.4ms) Expected results: User shouldn't be allowed to set a long value, we should define certain limit for any parameter. And if that limit exceeds, UI should throw an error message. Additional info: