[
https://issues.jboss.org/browse/WFLY-570?page=com.atlassian.jira.plugin.s...
]
Eduardo Silva commented on WFLY-570:
------------------------------------
Wouldn't that change cause an unnecessary overhead in the type conversion of ModelNode
class? Since the type mapping TypeModelValue does a simple map one x one regarding the
type conversion. Seems to me that being pemisive in this case could jeopardize performance
and be a precedent to further automatic type conversion allegations.
In ModelNode class
public ModelNode(final ModelType value) {
if (value == null) {
throw new IllegalArgumentException("value is null");
}
this.value = TypeModelValue.of(value);
}
In TypeModelValue
static TypeModelValue of(final ModelType type) {
switch (type) {
case BIG_DECIMAL:
return BIG_DECIMAL;
case BIG_INTEGER:
return BIG_INTEGER;
case BOOLEAN:
return BOOLEAN;
case BYTES:
return BYTES;
case DOUBLE:
return DOUBLE;
case EXPRESSION:
return EXPRESSION;
case INT:
return INT;
case LIST:
return LIST;
case LONG:
return LONG;
case OBJECT:
return OBJECT;
case PROPERTY:
return PROPERTY;
case STRING:
return STRING;
case TYPE:
return TYPE;
default:
return UNDEFINED;
}
}
Check ModelTypes in jacorb subsystem
------------------------------------
Key: WFLY-570
URL:
https://issues.jboss.org/browse/WFLY-570
Project: WildFly
Issue Type: Task
Components: Domain Management, IIOP
Affects Versions: 8.0.0.Alpha1
Reporter: Brian Stansberry
Fix For: 9.0.0.CR1
There are a number of attributes in the Jacorb subsystem that use ModelType.STRING for
things that look like booleans. Check through the attributes and change to
ModelType.BOOLEAN where appropriate.
This shouldn't raise a compatibility issue, since ModelType.BOOLEAN is freely
convertible to ModelType.STRING, and vice-versa so long as the string represents as
boolean (which it would have to do for the attribute to work anyway.) If anything is
changed though, a Console subtask should be created to look into any UI implications.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:
http://www.atlassian.com/software/jira