Class NodeInfo


  • public class NodeInfo
    extends JsonRepresentable
    Represents the current state of a Polaris host
           {
         "id": "embedded",
         "hostname": "polaris1",
         "uname": "Linux polaris1 5.10.16-arch1-1 #1 SMP PREEMPT Sat, 13 Feb 2021 20:50:18 +0000 x86_64 GNU/Linux",
         "architecture": "amd64",
         "processors": 16,
         "totalMemory": 67437092864,
         "freeMemory": 38039498752,
         "totalSwap": 24771100672,
         "freeSwap": 24771100672,
         "labels": {
             "aslr": "on"
         },
         "publicIP": "127.0.0.1",
         "osName": "Linux",
         "osVersion": "5.10.16-arch1-1",
         "cpuLoad": 6.22
       }
     
    • Constructor Detail

      • NodeInfo

        public NodeInfo​(java.lang.String id,
                        java.lang.String publicIP,
                        java.lang.String hostname,
                        java.lang.String uname,
                        java.lang.String architecture,
                        java.lang.String osName,
                        java.lang.String osVersion,
                        int processors,
                        double cpuLoad,
                        long totalMemory,
                        long freeMemory,
                        long totalSwap,
                        long freeSwap,
                        java.util.Map<java.lang.String,​java.lang.String> labels,
                        PortAllocations portAllocations,
                        java.util.List<java.lang.String> podImages,
                        java.util.List<java.lang.String> runners,
                        boolean schedulable)
        Parameters:
        id - the id of the host
        publicIP - the public ip of the host
        hostname - the hostname of the host
        uname - the kernel details of the host
        architecture - the architecture of the host
        osName - the name of the operating system
        osVersion - the version of the operating system
        processors - how many processors are available
        cpuLoad - the average cpu load across all cores in the last minute
        totalMemory - total system memory
        freeMemory - free system memory
        totalSwap - total swap space on the host
        freeSwap - free swap space on the host
        labels - labels added to the host
        portAllocations - ports allocated on the host
        podImages - pod images downloaded on the node
        runners - the runners available on the node
        schedulable - if the node is schedulable
    • Method Detail

      • getId

        public java.lang.String getId()
      • getPublicIP

        public java.lang.String getPublicIP()
      • getHostname

        public java.lang.String getHostname()
      • getUname

        public java.lang.String getUname()
      • getArchitecture

        public java.lang.String getArchitecture()
      • getOsName

        public java.lang.String getOsName()
      • getOsVersion

        public java.lang.String getOsVersion()
      • getProcessors

        public int getProcessors()
      • getCpuLoad

        public double getCpuLoad()
      • getTotalMemory

        public long getTotalMemory()
      • getFreeMemory

        public long getFreeMemory()
      • getTotalSwap

        public long getTotalSwap()
      • getFreeSwap

        public long getFreeSwap()
      • getLabels

        public java.util.Map<java.lang.String,​java.lang.String> getLabels()
      • getPodImages

        public java.util.List<java.lang.String> getPodImages()
      • getRunners

        public java.util.List<java.lang.String> getRunners()
      • isSchedulable

        public boolean isSchedulable()
      • equals

        public boolean equals​(java.lang.Object o)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object