ZookeeperInfo.java 722 字节
Newer Older
Z
zengqiao 已提交
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42
package com.xiaojukeji.know.streaming.km.common.bean.entity.zookeeper;

import com.xiaojukeji.know.streaming.km.common.bean.entity.BaseEntity;
import com.xiaojukeji.know.streaming.km.common.constant.Constant;
import lombok.Data;

@Data
public class ZookeeperInfo extends BaseEntity {
    /**
     * 集群Id
     */
    private Long clusterPhyId;

    /**
     * 主机
     */
    private String host;

    /**
     * 端口
     */
    private Integer port;

    /**
     * 角色
     */
    private String role;

    /**
     * 版本
     */
    private String version;

    /**
     * ZK状态
     */
    private Integer status;

    public boolean alive() {
        return !(Constant.DOWN.equals(status));
    }
}