Bug 1005186 - Unable to undefine attribute enable-welcome-root for virtual server via CLI
Summary: Unable to undefine attribute enable-welcome-root for virtual server via CLI
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss Enterprise Application Platform 6
Classification: JBoss
Component: Web
Version: 6.1.1
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ER7
: EAP 6.2.0
Assignee: Chao Wang
QA Contact: Radim Hatlapatka
Russell Dickenson
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-09-06 11:36 UTC by Radim Hatlapatka
Modified: 2013-12-15 16:20 UTC (History)
2 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2013-12-15 16:20:17 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Radim Hatlapatka 2013-09-06 11:36:45 UTC
Description of problem:
Instead of attribute enable-welcome-root being undefined it is set to a default value

Version-Release number of selected component (if applicable):
EAP 6.1.1

How reproducible: always


Steps to Reproduce:
1. /subsystem=web/virtual-server=default-host:undefine-attribute(name=enable-welcome-root)
2. /subsystem=web/virtual-server=default-host:read-attribute(include-defaults=false, name=enable-welcome-root)


Actual results:

false

Expected results:

undefined


Additional info:
read-resource-description shows that this attribute is nillable

Comment 1 Chao Wang 2013-09-27 08:49:56 UTC
This because that SimpleAttribute 'enable-welcome-root' is nillable but has a default value set to false and WriteEnableWelcomeRoot considers all non-true value as a false value, Thus, user can't undefine it.

I have prepared a fix on https://github.com/soul2zimate/jboss-eap/commit/848349cec769600e7be012b9bfc2ca759a41b367

However, I wonder if it's intended to work like that? if true, we only need to revise attribute description to non-nullable and accept false as default value.

Comment 3 Radim Hatlapatka 2013-11-04 12:34:44 UTC
Verified in EAP 6.2.0.ER7


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