cshannon commented on code in PR #1329:
URL: https://github.com/apache/activemq/pull/1329#discussion_r1888673125
##########
activemq-client/src/main/java/org/apache/activemq/management/StatisticImpl.java:
##########
@@ -83,32 +89,31 @@ public synchronized long getLastSampleTime() {
/**
* @return the enabled
*/
- public boolean isEnabled() {
+ public synchronized boolean isEnabled() {
Review Comment:
There is no benefit to making these methods synchronized, the variables are
already volatile and reading or setting the boolean is atomic
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information, visit: https://activemq.apache.org/contact