]
Brian Stansberry reassigned WFCORE-3682:
----------------------------------------
Assignee: (was: Brian Stansberry)
read-resource operation has no failure-description when fails to get
a metric attribute value
---------------------------------------------------------------------------------------------
Key: WFCORE-3682
URL:
https://issues.jboss.org/browse/WFCORE-3682
Project: WildFly Core
Issue Type: Bug
Components: Domain Management
Environment: WildFly 13 with WFLY-5603 merged.
Reporter: Lin Gao
{panel:title=PLEASE NOTE}
This issue is found when verifying the feature: WFLY-5603, which is not merged yet.
I think the issue belongs to WFCORE, because it should be a general issue although I
cannot find other similar cases yet.
{panel}
----
When trying to run *:read-resource(include-runtime=true)* command on some managed model
resources, and some runtime attributes like metrics are failed to get the value, the
*failure-description* is missing from the CLI result.
----
The initial analysis is related with the *rollback-on-runtime-failure* in
*operation-headers*.
ReadResourceAssemblyHandler [is added into the VERIFY stage for runtime
query|https://github.com/wildfly/wildfly-core/blob/4.0.0.Final/controller...]
to assemble each attribute result. But if one runtime attribute of a model resource fails
to get the value, the OperationContext [won't
continue|https://github.com/wildfly/wildfly-core/blob/4.0.0.Final/control...]
because the [current
implementation|https://github.com/wildfly/wildfly-core/blob/4.0.0.Final/c...]
is checking whether the *ContextFlag.ROLLBACK_ON_FAIL* exists in operation headers.
But trying to put such operation header into the operation headers may lead to the whole
CLI succeeds even there are failures for the runtime attributes.