[
https://issues.jboss.org/browse/WFCORE-4267?page=com.atlassian.jira.plugi...
]
Brian Stansberry edited comment on WFCORE-4267 at 1/10/19 6:53 PM:
-------------------------------------------------------------------
Thanks, Jaikiran.
ThreadMXBeanDumpAllThreadsHandler is quite old code and isn't using the
AttributeDefinition object that provides the description data to also handle reading the
param from the request. The AD has default value handling logic and the old code does not.
So that's why setting the params is needed. That's a simple fix.
Re: the text descriptions, they are booleans, and here's what the text should say:
https://github.com/wildfly/wildfly-core/blob/master/platform-mbean/src/ma...
-For some reason it looks like it's instead outputting the text for the operation
reply:
https://github.com/wildfly/wildfly-core/blob/master/platform-mbean/src/ma...
That, I don't know why.-
I know why; there's a different property that has the wrong text.
was (Author: brian.stansberry):
Thanks, Jaikiran.
ThreadMXBeanDumpAllThreadsHandler is quite old code and isn't using the
AttributeDefinition object that provides the description data to also handle reading the
param from the request. The AD has default value handling logic and the old code does not.
So that's why setting the params is needed. That's a simple fix.
Re: the text descriptions, they are booleans, and here's what the text should say:
https://github.com/wildfly/wildfly-core/blob/master/platform-mbean/src/ma...
For some reason it looks like it's instead outputting the text for the operation
reply:
https://github.com/wildfly/wildfly-core/blob/master/platform-mbean/src/ma...
That, I don't know why.
dump-all-threads management operation forces explicit setting of
locked-monitors and locked-syncrhonizers
---------------------------------------------------------------------------------------------------------
Key: WFCORE-4267
URL:
https://issues.jboss.org/browse/WFCORE-4267
Project: WildFly Core
Issue Type: Bug
Components: Management
Affects Versions: 7.0.0.Final
Environment: WildFly server 15.0.0.Final
Reporter: jaikiran pai
Assignee: Jeff Mesnil
Priority: Major
The {{dump-all-threads}} exposed by {{/core-service=platform-mbean/type=threading}} has
this resource operation description:
{code}
....
"request-properties" => {
"locked-monitors" => {
"type" => BOOLEAN,
"description" => "A list of detyped representations
java.lang.management.MonitorInfo objects, each of w
hich represents an object monitor currently locked by the thread.",
"expressions-allowed" => false,
"required" => false,
"nillable" => true,
"default" => false
},
"locked-synchronizers" => {
"type" => BOOLEAN,
"description" => "A list of detyped representations
java.lang.management.LockInfo objects, each of whic
h represents an ownable synchronizer currently locked by the thread.",
"expressions-allowed" => false,
"required" => false,
"nillable" => true,
"default" => false
}
...
{code}
The {{locked-monitors}} and {{locked-synchronizers}} both are mentioned as
{{required=false}} and with default values. However, when I run this operation as follows
on a (standalone) WildFly 15.0.0.Final instance:
{code}
/core-service=platform-mbean/type=threading:dump-all-threads
{code}
I get:
{code}
{
"outcome" => "failed",
"failure-description" => "WFLYCTL0155:
'locked-synchronizers' may not be null",
"rolled-back" => true
}
{code}
when I then pass, locked-synchronizers explicitly as an attribute, it then complains
about locked-monitors being absent. The only way to get past this is to specify both those
attributes in the operation.
By the way, the description of those attributes isn't too clear, IMO. Is it saying
that the attribute represents a "list of detyped representations ...." ? In
which case the type of BOOLEAN for that attribute would be incorrect. Or does it mean that
if set to true then a "list of detyped representations ...." will be returned?
--
This message was sent by Atlassian Jira
(v7.12.1#712002)