[
https://issues.apache.org/jira/browse/IGNITE-7616?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16728759#comment-16728759
]
Eduard Shangareev commented on IGNITE-7616:
-------------------------------------------
[~syssoftsol], hi! I looked through, looks good, but there is no any test. And
there are already conflicts with master :(
{code}
ObjectName anyInstance =
ignite.configuration().getMBeanServer().queryNames(null,
Query.isInstanceOf(new
StringValueExp("org.apache.YourMXBeanClassName"))).iterator().next();
// Invoke operation
Object val =
ignite.configuration().getMBeanServer().invoke(anyInstance, "yourMethod", null,
null);
{code}
You could use this snippet for test coverage of new MX bean.
> GridDataStreamExecutor and GridCallbackExecutor JMX beans return incorrect
> values due to invalid interface registration.
> ------------------------------------------------------------------------------------------------------------------------
>
> Key: IGNITE-7616
> URL: https://issues.apache.org/jira/browse/IGNITE-7616
> Project: Ignite
> Issue Type: Bug
> Affects Versions: 2.4
> Reporter: Max Shonichev
> Assignee: David Harvey
> Priority: Major
> Labels: jmx
> Fix For: 2.8
>
> Attachments: image-2018-10-03-10-23-24-676.png,
> image-2018-10-03-10-24-12-459.png, master_1b3742f4d7_mxbeans_threads2.patch
>
>
> Two of newly added management beans as a result of implementing feature
> request https://issues.apache.org/jira/browse/IGNITE-7217 have bugs:
> # GridDataStreamExecutor is registered as conforming to ThreadPoolMXBean
> interface, though actually it is an incompatible StripedExecutor.
> # GridCallbackExecutor is registered as conforming to ThreadPoolMXBean
> interface, though actually it is an incompatible
> IgniteStripedThreadPoolExecutor.
> # ThreadPoolMXBeanAdapter checks whether adapted instance is
> ThreadPoolExecutor, and as interfaces are incompatible, most of the JMX
> attributes of GridCallbackExecutor and GridDataStreamExecutor are returned as
> -1 or null.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)