Class LinuxCPU

java.lang.Object
io.github.alersrt.pod4j.openapi.model.LinuxCPU
All Implemented Interfaces:
Serializable

@Generated("org.openapitools.codegen.languages.JavaClientCodegen") public class LinuxCPU extends Object implements Serializable
LinuxCPU for Linux cgroup 'cpu' resource management
See Also:
  • Field Details

  • Constructor Details

    • LinuxCPU

      public LinuxCPU()
  • Method Details

    • burst

      public LinuxCPU burst(Integer burst)
    • getBurst

      @Nullable public Integer getBurst()
      CPU hardcap burst limit (in usecs). Allowed accumulated cpu time additionally for burst in a given period.
      Returns:
      burst
    • setBurst

      public void setBurst(Integer burst)
    • cpus

      public LinuxCPU cpus(String cpus)
    • getCpus

      @Nullable public String getCpus()
      CPUs to use within the cpuset. Default is to use any CPU available.
      Returns:
      cpus
    • setCpus

      public void setCpus(String cpus)
    • idle

      public LinuxCPU idle(Long idle)
    • getIdle

      @Nullable public Long getIdle()
      cgroups are configured with minimum weight, 0: default behavior, 1: SCHED_IDLE.
      Returns:
      idle
    • setIdle

      public void setIdle(Long idle)
    • mems

      public LinuxCPU mems(String mems)
    • getMems

      @Nullable public String getMems()
      List of memory nodes in the cpuset. Default is to use any available memory node.
      Returns:
      mems
    • setMems

      public void setMems(String mems)
    • period

      public LinuxCPU period(Integer period)
    • getPeriod

      @Nullable public Integer getPeriod()
      CPU period to be used for hardcapping (in usecs).
      Returns:
      period
    • setPeriod

      public void setPeriod(Integer period)
    • quota

      public LinuxCPU quota(Long quota)
    • getQuota

      @Nullable public Long getQuota()
      CPU hardcap limit (in usecs). Allowed cpu time in a given period.
      Returns:
      quota
    • setQuota

      public void setQuota(Long quota)
    • realtimePeriod

      public LinuxCPU realtimePeriod(Integer realtimePeriod)
    • getRealtimePeriod

      @Nullable public Integer getRealtimePeriod()
      CPU period to be used for realtime scheduling (in usecs).
      Returns:
      realtimePeriod
    • setRealtimePeriod

      public void setRealtimePeriod(Integer realtimePeriod)
    • realtimeRuntime

      public LinuxCPU realtimeRuntime(Long realtimeRuntime)
    • getRealtimeRuntime

      @Nullable public Long getRealtimeRuntime()
      How much time realtime scheduling may use (in usecs).
      Returns:
      realtimeRuntime
    • setRealtimeRuntime

      public void setRealtimeRuntime(Long realtimeRuntime)
    • shares

      public LinuxCPU shares(Integer shares)
    • getShares

      @Nullable public Integer getShares()
      CPU shares (relative weight (ratio) vs. other cgroups with cpu shares).
      Returns:
      shares
    • setShares

      public void setShares(Integer shares)
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • validateJsonObject

      public static void validateJsonObject(com.google.gson.JsonObject jsonObj) throws IOException
      Validates the JSON Object and throws an exception if issues found
      Parameters:
      jsonObj - JSON Object
      Throws:
      IOException - if the JSON Object is invalid with respect to LinuxCPU
    • fromJson

      public static LinuxCPU fromJson(String jsonString) throws IOException
      Create an instance of LinuxCPU given an JSON string
      Parameters:
      jsonString - JSON string
      Returns:
      An instance of LinuxCPU
      Throws:
      IOException - if the JSON string is invalid with respect to LinuxCPU
    • toJson

      public String toJson()
      Convert an instance of LinuxCPU to an JSON string
      Returns:
      JSON string