All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.zodiac.monitor.data.Service Maven / Gradle / Ivy

package org.zodiac.monitor.data;

import com.fasterxml.jackson.annotation.JsonProperty;

import java.util.List;
import java.util.Map;

/**
 * model details see https://www.consul.io/api/catalog.html#serviceport
 *
 * @author consul
 */

public class Service {

    @JsonProperty("Address")
    private String address;

    @JsonProperty("Node")
    private String node;

    @JsonProperty("ServiceAddress")
    private String serviceAddress;

    @JsonProperty("ServiceName")
    private String serviceName;

    @JsonProperty("ServiceID")
    private String serviceId;

    @JsonProperty("ServicePort")
    private int servicePort;

    @JsonProperty("NodeMeta")
    private Map nodeMeta;

    @JsonProperty("ServiceMeta")
    private Map serviceMeta;

    /**
     * will be empty, eureka does not have the concept of service tags
     */
    @JsonProperty("ServiceTags")
    private List serviceTags;

    public Service() {}

    public String getAddress() {
        return address;
    }

    public Service setAddress(String address) {
        this.address = address;
        return this;
    }

    public String getNode() {
        return node;
    }

    public Service setNode(String node) {
        this.node = node;
        return this;
    }

    public String getServiceAddress() {
        return serviceAddress;
    }

    public Service setServiceAddress(String serviceAddress) {
        this.serviceAddress = serviceAddress;
        return this;
    }

    public String getServiceName() {
        return serviceName;
    }

    public Service setServiceName(String serviceName) {
        this.serviceName = serviceName;
        return this;
    }

    public String getServiceId() {
        return serviceId;
    }

    public Service setServiceId(String serviceId) {
        this.serviceId = serviceId;
        return this;
    }

    public int getServicePort() {
        return servicePort;
    }

    public Service setServicePort(int servicePort) {
        this.servicePort = servicePort;
        return this;
    }

    public Map getNodeMeta() {
        return nodeMeta;
    }

    public Service setNodeMeta(Map nodeMeta) {
        this.nodeMeta = nodeMeta;
        return this;
    }

    public Map getServiceMeta() {
        return serviceMeta;
    }

    public Service setServiceMeta(Map serviceMeta) {
        this.serviceMeta = serviceMeta;
        return this;
    }

    public List getServiceTags() {
        return serviceTags;
    }

    public Service setServiceTags(List serviceTags) {
        this.serviceTags = serviceTags;
        return this;
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy