Github user aledsage commented on a diff in the pull request:

    https://github.com/apache/incubator-brooklyn/pull/790#discussion_r36795378
  
    --- Diff: software/base/src/main/java/brooklyn/event/feed/jmx/JmxFeed.java 
---
    @@ -198,6 +198,7 @@ protected JmxFeed(Builder builder) {
             
             SetMultimap<String, JmxAttributePollConfig<?>> attributePolls = 
HashMultimap.<String,JmxAttributePollConfig<?>>create();
             for (JmxAttributePollConfig<?> config : builder.attributePolls) {
    +            if (!config.isEnabled()) continue;
    --- End diff --
    
    These are tricky. Not sure I follow your suggestion of "adding 
`builder.enabledPolls`"? If we put the config into `attributePolls`, then 
`preStart()` would need to do the filtering. For example, in 
`registerAttributePoller` it would need to guard the call to 
`getPoller().scheduleAtFixedRate` if they were all disabled and ensure the 
handler(s) didn't get called. It would also need to set minPeriod appropriately 
(i.e. miss out the value of disabled poll configs).


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to