brooklyn-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aledsage <...@git.apache.org>
Subject [GitHub] incubator-brooklyn pull request: Add basic sensors to RedisCluster
Date Tue, 04 Aug 2015 22:34:15 GMT
Github user aledsage commented on a diff in the pull request:

    https://github.com/apache/incubator-brooklyn/pull/782#discussion_r36250755
  
    --- Diff: software/nosql/src/main/java/brooklyn/entity/nosql/redis/RedisClusterImpl.java
---
    @@ -20,64 +20,111 @@
     
     import java.util.Collection;
     
    -import brooklyn.entity.Entity;
    +import brooklyn.enricher.Enrichers;
     import brooklyn.entity.basic.AbstractEntity;
    -import brooklyn.entity.basic.Entities;
    +import brooklyn.entity.basic.Lifecycle;
    +import brooklyn.entity.basic.ServiceStateLogic;
    +import brooklyn.entity.basic.ServiceStateLogic.ComputeServiceIndicatorsFromChildrenAndMembers;
    +import brooklyn.entity.basic.ServiceStateLogic.ServiceProblemsLogic;
     import brooklyn.entity.group.DynamicCluster;
     import brooklyn.entity.proxying.EntitySpec;
    -import brooklyn.entity.trait.Startable;
    +import brooklyn.event.AttributeSensor;
    +import brooklyn.event.basic.Sensors;
     import brooklyn.location.Location;
    +import brooklyn.util.collections.QuorumCheck.QuorumChecks;
    +import brooklyn.util.exceptions.Exceptions;
    +
    +import com.google.common.collect.ImmutableList;
    +import com.google.common.collect.ImmutableMap;
    +import com.google.common.collect.ImmutableSet;
     
     public class RedisClusterImpl extends AbstractEntity implements RedisCluster {
     
    -    protected RedisStore master;
    -    protected DynamicCluster slaves;
    +    private static AttributeSensor<RedisStore> MASTER = Sensors.newSensor(RedisStore.class,
"redis.master");
    --- End diff --
    
    I'd declare it `final` as well, given it is a constant.


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message