Bug 915510 - Exception is thrown when trying to update System Name greater than 255 Characters
Summary: Exception is thrown when trying to update System Name greater than 255 Charac...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Subscription Asset Manager
Classification: Retired
Component: katello
Version: 1.3
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Bryan Kearney
QA Contact: SAM QE List
URL:
Whiteboard:
Depends On:
Blocks: sam20-tracker
TreeView+ depends on / blocked
 
Reported: 2013-02-25 22:54 UTC by sthirugn@redhat.com
Modified: 2014-06-27 21:02 UTC (History)
3 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2014-06-27 21:02:37 UTC
Embargoed:


Attachments (Terms of Use)
Exception when System Name is greater than 255 characters (88.66 KB, image/png)
2013-02-25 22:54 UTC, sthirugn@redhat.com
no flags Details

Description sthirugn@redhat.com 2013-02-25 22:54:57 UTC
Created attachment 702549 [details]
Exception when System Name is greater than 255 characters

Description of problem:
Exception is thrown when trying to update the Name of the Subscribed system with more than 255 characters

Version-Release number of selected component (if applicable):
* candlepin-0.7.23-1.el6_3.noarch
* candlepin-cert-consumer-cloud-qe-9.idm.lab.bos.redhat.com-1.0-1.noarch
* candlepin-tomcat6-0.7.23-1.el6_3.noarch
* elasticsearch-0.19.9-5.el6_3.noarch
* katello-candlepin-cert-key-pair-1.0-1.noarch
* katello-certs-tools-1.2.1-1h.el6_3.noarch
* katello-cli-1.2.1-12h.el6_3.noarch
* katello-cli-common-1.2.1-12h.el6_3.noarch
* katello-common-1.2.1-15h.el6_3.noarch
* katello-configure-1.2.3-3h.el6_3.noarch
* katello-glue-candlepin-1.2.1-15h.el6_3.noarch
* katello-headpin-1.2.1-15h.el6_3.noarch
* katello-headpin-all-1.2.1-15h.el6_3.noarch
* katello-selinux-1.2.1-2h.el6_3.noarch
* thumbslug-0.0.28-1.el6_3.noarch
* thumbslug-selinux-0.0.28-1.el6_3.noarch

How reproducible:
Always

Steps to Reproduce:
1. Log in to SAM
2. Navigate to Systems page and click on a System
3. Go to Details Tab -> System Info -> Click to edit System Name under System Properties
4. Update Name with a text more than 255 characters:
test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain.test.domain
  
Actual results:
Exception is thrown (see attached screenshot)

Expected results:
Error message saying System Name cannot be greater than 255 characters:
"System Name cannot contain more than 255 characters"

Additional info:
1.Other editable fields in this page - Description and Location show proper error message in this scenario.
2.System Name is properly updated with a text equal to 255 characters.

Comment 1 Tom McKay 2013-07-22 16:45:23 UTC
Name is validated but displayed message is slightly confusing:

Validation Failed:
Name is too long (maximum is 250 characters)
Name cannot contain more than 255 characters

Two differing validations?

Comment 2 Payal Godhani 2013-08-02 18:18:44 UTC
https://github.com/Katello/katello/pull/2717

Comment 4 Bryan Kearney 2013-08-14 19:23:34 UTC
Will be in 1.4.3-9-sat or later.

Comment 5 sthirugn@redhat.com 2013-08-20 21:26:18 UTC
Failed.

Currently seeing the same messages as mentioned in Comment 1 above.  This needs to be fixed to show a clear error message to the user.

Validation Failed:
    Name is too long (maximum is 250 characters)
    Name cannot contain more than 255 characters

Version Tested:
* candlepin-0.8.20-1.el6sam.noarch
* candlepin-cert-consumer-cloud-qe-21.idm.lab.bos.redhat.com-1.0-1.noarch
* candlepin-scl-1-5.el6_4.noarch
* candlepin-scl-quartz-2.1.5-5.el6_4.noarch
* candlepin-scl-rhino-1.7R3-1.el6_4.noarch
* candlepin-scl-runtime-1-5.el6_4.noarch
* candlepin-selinux-0.8.20-1.el6sam.noarch
* candlepin-tomcat6-0.8.20-1.el6sam.noarch
* elasticsearch-0.19.9-8.el6sat.noarch
* katello-candlepin-cert-key-pair-1.0-1.noarch
* katello-certs-tools-1.4.2-2.el6sat.noarch
* katello-cli-1.4.3-7.el6sat.noarch
* katello-cli-common-1.4.3-7.el6sat.noarch
* katello-common-1.4.3-8.el6sam_splice.noarch
* katello-configure-1.4.4-2.el6sat.noarch
* katello-glue-candlepin-1.4.3-8.el6sam_splice.noarch
* katello-glue-elasticsearch-1.4.3-8.el6sam_splice.noarch
* katello-headpin-1.4.3-8.el6sam_splice.noarch
* katello-headpin-all-1.4.3-8.el6sam_splice.noarch
* katello-selinux-1.4.4-2.el6sat.noarch
* thumbslug-0.0.32-1.el6sam.noarch
* thumbslug-selinux-0.0.32-1.el6sam.noarch

Comment 7 sthirugn@redhat.com 2014-06-27 21:02:37 UTC
This works fine in SAM 1.4.

Now the following UI message is displayed:
Validation Failed:
    Name cannot contain more than 255 characters


Note You need to log in before you can comment on or make changes to this bug.