Class KubernetesComputer

All Implemented Interfaces:
ExtensionPoint, DescriptorByNameOwner, ExecutorListener, ModelObject, SearchableModelObject, SearchItem, AccessControlled, IComputer, ModelObjectWithContextMenu, HasWidgets, IconSpec, org.kohsuke.stapler.StaplerProxy

public class KubernetesComputer extends AbstractCloudComputer<KubernetesSlave>
Author:
Carlos Sanchez carlos@apache.org
  • Constructor Details

  • Method Details

    • taskAccepted

      public void taskAccepted(Executor executor, Queue.Task task)
      Specified by:
      taskAccepted in interface ExecutorListener
      Overrides:
      taskAccepted in class SlaveComputer
    • taskCompleted

      public void taskCompleted(Executor executor, Queue.Task task, long durationMS)
      Specified by:
      taskCompleted in interface ExecutorListener
      Overrides:
      taskCompleted in class SlaveComputer
    • taskCompletedWithProblems

      public void taskCompletedWithProblems(Executor executor, Queue.Task task, long durationMS, Throwable problems)
      Specified by:
      taskCompletedWithProblems in interface ExecutorListener
      Overrides:
      taskCompletedWithProblems in class SlaveComputer
    • getContainers

      @Exported public List<io.fabric8.kubernetes.api.model.Container> getContainers() throws org.jenkinsci.plugins.kubernetes.auth.KubernetesAuthException, IOException
      Throws:
      org.jenkinsci.plugins.kubernetes.auth.KubernetesAuthException
      IOException
    • getPodEvents

      @Exported public List<io.fabric8.kubernetes.api.model.Event> getPodEvents() throws org.jenkinsci.plugins.kubernetes.auth.KubernetesAuthException, IOException
      Throws:
      org.jenkinsci.plugins.kubernetes.auth.KubernetesAuthException
      IOException
    • doContainerLog

      public void doContainerLog(@QueryParameter String containerId, org.kohsuke.stapler.StaplerRequest2 req, org.kohsuke.stapler.StaplerResponse2 rsp) throws org.jenkinsci.plugins.kubernetes.auth.KubernetesAuthException, IOException
      Throws:
      org.jenkinsci.plugins.kubernetes.auth.KubernetesAuthException
      IOException
    • toString

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

      @NonNull public ACL getACL()
    • annotateTtl

      public void annotateTtl(TaskListener listener)
    • setLaunching

      public void setLaunching(boolean launching)
    • isLaunching

      public boolean isLaunching()
      Returns:
      true if the Pod has been created in Kubernetes and the current instance is waiting for the pod to be usable.
    • setAcceptingTasks

      public void setAcceptingTasks(boolean acceptingTasks)
      Overrides:
      setAcceptingTasks in class SlaveComputer