[jboss-as7-dev] inconsistent expression support
Jeff Mesnil
jmesnil at redhat.com
Thu Dec 13 10:46:59 EST 2012
On 12/13/2012 09:56 AM, Heiko Braun wrote:
>
>
> opening up the configuration to support expressions all over the place is desirable, but I wonder how far away we are from actually supporting it. We've been very restrictive in the console with using expressions, now we support it by default on all attributes. This is what happens:
>
> https://issues.jboss.org/browse/AS7-6154
>
> I wonder how we can actually verify full expression support, apart from simply declaring support in the meta data. IMO it would require to iterate over the current stock config and replace all occurrences of attributes that declare support for it with a default expression.
That's what I did for the messaging subsystem. I used expressions in the subsystem XML tests for every attributes that are now
allowing them.
I found a few bugs like yours doing that but that was not enough.
Another thing was to check during XML parsing for STRING attributes. Some have their value set and not parsed using
AttributeDefinition.parseAndSetParameter() or ParseUtils functions. This results in a STRING ModelType (a literal
"${exp:default}") while it must be an EXPRESSION instead.
I had also to fix a few calls at runtime where the attribute value was not fetched using
AttributeDefinition.resolveModelAttribute() and the expression was not resolved.
These errors occurs at runtime and were easy to miss (I may not have found all of them).
jeff
--
Jeff Mesnil
JBoss, a division of Red Hat
http://jmesnil.net/
More information about the jboss-as7-dev
mailing list