Class InboundLaunchStrategy

All Implemented Interfaces:
ExtensionPoint, Describable<AgentLaunchStrategy>

public class InboundLaunchStrategy extends AgentLaunchStrategy
Runs the Jenkins inbound agent as a Namespace-managed container, which dials out to the controller over WebSocket.

Namespace-managed containers (those declared at creation time) are treated as critical: if the agent process exits, the instance fails as a whole, which makes a dead agent visible rather than leaving an idle VM burning budget.

  • Field Details

    • DEFAULT_IMAGE

      public static final String DEFAULT_IMAGE
      Default agent image. The JDK tag should track the controller's Java major version so remoting negotiates a matching protocol.
      See Also:
  • Constructor Details

    • InboundLaunchStrategy

      @DataBoundConstructor public InboundLaunchStrategy()
  • Method Details

    • getImage

      public String getImage()
    • setImage

      @DataBoundSetter public void setImage(String image)
    • isWebSocket

      public boolean isWebSocket()
    • setWebSocket

      @DataBoundSetter public void setWebSocket(boolean webSocket)
    • isExposeDockerSocket

      public boolean isExposeDockerSocket()
    • setExposeDockerSocket

      @DataBoundSetter public void setExposeDockerSocket(boolean exposeDockerSocket)
    • requiresNodeRegisteredFirst

      public boolean requiresNodeRegisteredFirst()
      Description copied from class: AgentLaunchStrategy
      Whether the Jenkins node must be registered before the instance is created. True for inbound: the agent connects on its own and the controller rejects a connection from a node it does not know about yet.
      Overrides:
      requiresNodeRegisteredFirst in class AgentLaunchStrategy
    • configureInstance

      public void configureInstance(@NonNull Compute.CreateInstanceRequest.Builder builder, @NonNull LaunchContext ctx)
      Description copied from class: AgentLaunchStrategy
      Contributes to the instance request before it is sent — typically the container that will host the agent, plus any credentials it needs.
      Specified by:
      configureInstance in class AgentLaunchStrategy
    • createLauncher

      @NonNull public ComputerLauncher createLauncher(@NonNull NamespaceClient client, @NonNull Compute.InstanceMetadata instance, @NonNull LaunchContext ctx)
      Description copied from class: AgentLaunchStrategy
      Builds the Jenkins-side launcher. Called once the instance is RUNNING, so implementations may query the instance for connection details.
      Specified by:
      createLauncher in class AgentLaunchStrategy