[ 
https://issues.apache.org/jira/browse/ARTEMIS-5262?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17937429#comment-17937429
 ] 

Vilius Šumskas commented on ARTEMIS-5262:
-----------------------------------------

I just enable commented out connector in *management.xml* as described here 
[https://activemq.apache.org/components/artemis/documentation/latest/management.html#role-based-authorisation-for-jmx]
 and connect to the management port 1099 directly.

It's hard to describe what happens in VisualVM as sometimes it acts unstable. I 
don't have a test system to try it now, but when I add Artemis JMX connection 
on the left, I then click on the connection entry and it should open window on 
the right. That window usually shows JVM statistics and MBean tab which allows 
you to browse Artemis MBeans. Without three permissions mentioned above 
VisualVM window on the right is completely empty. Even MBreans tab is missing.
Basically without these permissions I cannot browse Artemis MBeans even through 
my user has permissions in org.apache.artemis domain.

Screenshot here represent the usual state of the window (disconnected state).
!screenshot-1.png|width=565,height=371!

I don't think it would be serious issue to allow those three command as they 
mostly just return informational data.

> Allow VisualVM to browse JMX Mbeans by default
> ----------------------------------------------
>
>                 Key: ARTEMIS-5262
>                 URL: https://issues.apache.org/jira/browse/ARTEMIS-5262
>             Project: ActiveMQ Artemis
>          Issue Type: Improvement
>         Environment: VisualVM 2.1.0 on Windows 10
> ActiveMQ Artemis 2.39.0 on Java 17
>            Reporter: Vilius Šumskas
>            Priority: Minor
>         Attachments: screenshot-1.png
>
>
> When testing Artemis' JMX functionality with VisualVM 2.1.10 and Mbeans 
> plugin installed I have found that I'm unable to browse JMX Mbeans by 
> default. It looks like permissions are to strict to paint the initial 
> VisualVM window.
> Adding the following configuration to *<role-access>* section of 
> *management.xml* should solve the issue:
> {code:xml}
>          <match domain="com.sun.management">
>             <access method="help" roles="amq"/>
>             <access method="jfrCheck" roles="amq"/>
>             <access method="vmCommandLine" roles="amq"/>
>          </match>{code}
> There is also an additional exception about VisualVM unable to call 
> gcClassHistogram, but since it doesn't block other VisualVM operations and I 
> didn't know if that's not too sensitive to allow by default, so I didn't add 
> it.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information, visit: https://activemq.apache.org/contact


Reply via email to