summaryrefslogtreecommitdiffstats
path: root/controller-api/src/main/java/com/yahoo/vespa/hosted/controller/api/integration/configserver/NodeList.java
blob: 755bec2fcecc1794798b2916ce11e524f945ee7b (plain) (blame)
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
package com.yahoo.vespa.hosted.controller.api.integration.configserver;// Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonProperty;

import java.util.List;

/**
 * @author smorgrav
 */
@JsonIgnoreProperties(ignoreUnknown = true)
public class NodeList {

    @JsonProperty("nodes")
    public List<Node> nodes;

    @JsonIgnoreProperties(ignoreUnknown = true)
    public static class Node {
        @JsonProperty("hostname")
        public String hostname;
        @JsonProperty("flavor")
        public String flavor;
        @JsonProperty("membership")
        public Membership membership;
        @JsonProperty("cost")
        public int cost;

        @JsonIgnoreProperties(ignoreUnknown = true)
        public static class Membership {
            @JsonProperty("clustertype")
            public String clusterType;
            @JsonProperty("clusterid")
            public String clusterId;
        }
    }
}