[
https://issues.jboss.org/browse/WFLY-8085?page=com.atlassian.jira.plugin....
]
Brian Stansberry commented on WFLY-8085:
----------------------------------------
Using a composite alone isn't enough here. We also need to deal with other reasons why
the required attribute is invalid; e.g. it's a capability reference etc.
If the undefined required attribute has a default value we could set it to that. If it
doesn't, we can't set it regardless. But a required attribute would be undefined
but with a default value is either 1) illegal for reasons I'm too lazy to think
through now, or 2) a sign of a bad smelling management API and a real edge case. So, I
won't bother dealing with that.
Closing.
ExpressionSupportSmokeTestCase doesn't properly handle attributes
with undefined required attributes
----------------------------------------------------------------------------------------------------
Key: WFLY-8085
URL:
https://issues.jboss.org/browse/WFLY-8085
Project: WildFly
Issue Type: Bug
Components: Domain Management, Test Suite
Reporter: Brian Stansberry
Assignee: Brian Stansberry
ExpressionSupportSmokeTestCase is attempting to set attributes even when other required
attributes are undefined. In organizeAttributes it checks if the required attribute is
undefined due to the presence of a defined alternative, but if that's not the reason
it tries to set the base attribute. That will fail if the required attribute is undefined
simply because the base config doesn't define it.
https://github.com/wildfly/wildfly/pull/9628 includes a workaround for this, but it's
not ideal. We should look into how setExpressions works and change it from executing a
bunch of individual write-attribute ops per resource to executing them all as steps in a
single composite. That would remove any reason for leaving these attributes undefined.
Both the base attribute and the required attribute would be set in the same composite.
--
This message was sent by Atlassian JIRA
(v7.2.3#72005)