Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add spotVM and maxRunDuration feature to VM provisioning #492

Open
wants to merge 32 commits into
base: develop
Choose a base branch
from

Conversation

gbhat618
Copy link
Contributor

@gbhat618 gbhat618 commented Dec 11, 2024

Summary

This PR aims to enhance the VM provisioning capabilities of the google-compute-engine-plugin by introducing support for Spot VMs and maxRunDuration. This effort seeks to address the issues reported in #408, #473, and #358.

Enhancements

  • Spot VM Support: Incorporates the option to use Spot VMs, providing a cost-effective and efficient alternative to preemptible VMs without the automatic deletion after 24 hours.
  • maxRunDuration: Implements the maxRunDuration feature, enabling the automatic deletion of VMs after a specified duration to optimize resource utilization and cost.

Rationale

Although this plugin already has a background cleanup job for leftover orphan agent VMs, setting the maxRunDuration ensures that VMs deletion still happens even if the Jenkins controller itself has crashed. Besides this is an optional setting with no defaults enforced, so this feature is not trying to replace/interfere with the existing background job.

Technical Background

The plugin now supports the following VM options:

  • Standard VMs: Regular VM instances with guaranteed availability by GCP SLA and standard pricing. Also supports maxRunDuration.
  • Spot VMs: An updated version of Preemptible VMs, offering exactly same cost benefits without the restriction of automatic deletion after 24 hours.
  • Preemptible VMs: Cost-effective VM instances with limited availability, reclaimed by GCE after 24 hours.
Why Maintain Support for Both Spot and Preemptible VMs?

Despite the similarities between Spot and Preemptible VMs, retaining support for both options is essential for the following reasons:

  • Non-Deprecation by GCP: Google Cloud Platform does not plan to deprecate Preemptible VMs.
  • Backward Compatibility: Many Jenkins controllers are configured to use Preemptible VMs. Dropping support will disrupt existing setups.
  • Clear Differentiation: Retaining both options avoids confusion and simplifies the user experience, requiring no changes upon plugin upgrade.

Testing Status

Manual Tests: Screen recording and screenshots

User experience configuration page

provisioning_type_impl_2.mov

VM Provisioned in GCP

Description Content
Spot VM provisioned with max run duration 1200s
Standard VM provisioned with max run duration 600s
Preemptible VM as before

→ Unit tests for the scheduling() method, ensuring the compatibility with the old and new configurations.

New integration test for the Spot VM with Max Duration: logs
[INFO]  T E S T S
[INFO] -------------------------------------------------------
[INFO] Running com.google.jenkins.plugins.computeengine.integration.SpotVmProvisioningWithMaxRunDurationCasCIT
Jan 08, 2025 2:14:14 PM com.google.jenkins.plugins.computeengine.integration.ITUtil bootDiskProject
INFO: Using boot disk project: tiger-team-testing
Jan 08, 2025 2:14:14 PM com.google.jenkins.plugins.computeengine.integration.ITUtil bootDiskImageName
INFO: Using boot disk image: projects/tiger-team-testing/global/images/jenkins-gce-integration-test-jre
=== Starting testMaxRunDurationDeletesAndNoNewBuilds(com.google.jenkins.plugins.computeengine.integration.SpotVmProvisioningWithMaxRunDurationCasCIT)
   0.037 [id=21]	INFO	o.jvnet.hudson.test.WarExploder#explode: Picking up existing exploded jenkins.war at /Users/gbhat/CBProjects/google-compute-engine-plugin/target/jenkins-for-test
   0.132 [id=21]	INFO	o.jvnet.hudson.test.JenkinsRule#createWebServer: Running on http://localhost:61986/jenkins/
   0.312 [id=36]	INFO	jenkins.InitReactorRunner$1#onAttained: Started initialization
   0.927 [id=41]	WARNING	hudson.ClassicPluginStrategy#createClassJarFromWebInfClasses: Created /var/folders/80/w8mmdy513sb3y9fp5fr7vvqc0000gn/T/jenkins3593565348945833359/plugins/powershell/WEB-INF/lib/classes.jar; update plugin to a version created with a newer harness
   0.939 [id=41]	INFO	hudson.PluginManager#considerDetachedPlugin: Loading a detached plugin as a dependency: /var/folders/80/w8mmdy513sb3y9fp5fr7vvqc0000gn/T/jenkins3593565348945833359/plugins/matrix-auth.jpi
   0.963 [id=41]	INFO	hudson.PluginManager#considerDetachedPlugin: Loading a detached plugin as a dependency: /var/folders/80/w8mmdy513sb3y9fp5fr7vvqc0000gn/T/jenkins3593565348945833359/plugins/echarts-api.jpi
   1.199 [id=41]	INFO	hudson.PluginManager#considerDetachedPlugin: Loading a detached plugin as a dependency: /var/folders/80/w8mmdy513sb3y9fp5fr7vvqc0000gn/T/jenkins3593565348945833359/plugins/junit.jpi
   1.207 [id=41]	INFO	hudson.PluginManager#considerDetachedPlugin: Loading a detached plugin as a dependency: /var/folders/80/w8mmdy513sb3y9fp5fr7vvqc0000gn/T/jenkins3593565348945833359/plugins/jquery3-api.jpi
   1.214 [id=41]	INFO	hudson.PluginManager#considerDetachedPlugin: Loading a detached plugin as a dependency: /var/folders/80/w8mmdy513sb3y9fp5fr7vvqc0000gn/T/jenkins3593565348945833359/plugins/matrix-project.jpi
   1.224 [id=41]	INFO	hudson.PluginManager#considerDetachedPlugin: Loading a detached plugin as a dependency: /var/folders/80/w8mmdy513sb3y9fp5fr7vvqc0000gn/T/jenkins3593565348945833359/plugins/checks-api.jpi
   1.230 [id=41]	INFO	hudson.PluginManager#considerDetachedPlugin: Loading a detached plugin as a dependency: /var/folders/80/w8mmdy513sb3y9fp5fr7vvqc0000gn/T/jenkins3593565348945833359/plugins/command-launcher.jpi
   1.236 [id=41]	INFO	hudson.PluginManager#considerDetachedPlugin: Loading a detached plugin as a dependency: /var/folders/80/w8mmdy513sb3y9fp5fr7vvqc0000gn/T/jenkins3593565348945833359/plugins/jdk-tool.jpi
   1.247 [id=41]	INFO	hudson.PluginManager#considerDetachedPlugin: Loading a detached plugin as a dependency: /var/folders/80/w8mmdy513sb3y9fp5fr7vvqc0000gn/T/jenkins3593565348945833359/plugins/mina-sshd-api-common.jpi
   1.257 [id=41]	INFO	hudson.PluginManager#considerDetachedPlugin: Loading a detached plugin as a dependency: /var/folders/80/w8mmdy513sb3y9fp5fr7vvqc0000gn/T/jenkins3593565348945833359/plugins/mina-sshd-api-core.jpi
   1.267 [id=41]	INFO	hudson.PluginManager#considerDetachedPlugin: Loading a detached plugin as a dependency: /var/folders/80/w8mmdy513sb3y9fp5fr7vvqc0000gn/T/jenkins3593565348945833359/plugins/sshd.jpi
   1.274 [id=41]	INFO	hudson.PluginManager#considerDetachedPlugin: Loading a detached plugin as a dependency: /var/folders/80/w8mmdy513sb3y9fp5fr7vvqc0000gn/T/jenkins3593565348945833359/plugins/javax-mail-api.jpi
   1.532 [id=35]	INFO	jenkins.InitReactorRunner$1#onAttained: Listed all plugins
   1.538 [id=56]	INFO	j.b.api.BouncyCastlePlugin#start: /Users/gbhat/CBProjects/google-compute-engine-plugin/target/tmp/j h1716315002771573716/plugins/bouncycastle-api/WEB-INF/optional-lib not found; for non RealJenkinsRule this is fine and can be ignored.
   2.288 [id=55]	INFO	jenkins.InitReactorRunner$1#onAttained: Prepared all plugins
   2.293 [id=53]	INFO	jenkins.InitReactorRunner$1#onAttained: Started all plugins
   2.293 [id=57]	INFO	jenkins.InitReactorRunner$1#onAttained: Augmented all extensions
   2.613 [id=44]	INFO	jenkins.InitReactorRunner$1#onAttained: System config loaded
   2.642 [id=37]	INFO	jenkins.InitReactorRunner$1#onAttained: System config adapted
   2.642 [id=52]	INFO	jenkins.InitReactorRunner$1#onAttained: Loaded all jobs
   2.643 [id=40]	INFO	jenkins.InitReactorRunner$1#onAttained: Configuration for all jobs updated
   2.711 [id=41]	INFO	jenkins.InitReactorRunner$1#onAttained: Completed initialization
   2.762 [id=21]	INFO	c.g.j.p.c.i.SpotVmProvisioningWithMaxRunDurationCasCIT#setUp: init
   2.793 [id=21]	INFO	c.g.j.p.c.i.SpotVmProvisioningWithMaxRunDurationCasCIT#setUp: init complete
   2.829 [id=21]	WARNING	i.j.p.casc.BaseConfigurator#createAttribute: Can't handle class com.google.jenkins.plugins.computeengine.InstanceConfiguration#sshKeyCredential: type is abstract but not Describable.
   2.836 [id=21]	WARNING	i.j.p.casc.BaseConfigurator#createAttribute: Can't handle class com.google.jenkins.plugins.computeengine.InstanceConfiguration#sshKeyCredential: type is abstract but not Describable.
   2.982 [id=21]	INFO	c.g.j.p.c.ComputeEngineCloud#provision: Provisioning node from configs [com.google.jenkins.plugins.computeengine.InstanceConfiguration@545a028e] for excess workload of 1 units of label 'integration'
   5.201 [id=21]	INFO	c.g.j.p.c.ComputeEngineCloud#availableNodeCapacity: Found capacity for 10 nodes in cloud integration
   5.203 [id=21]	INFO	c.g.j.p.c.InstanceConfiguration#instance: User selected to use an autogenerated ssh key pair
   7.586 [id=21]	INFO	c.g.j.p.c.InstanceConfiguration#provision: Sent insert request for instance configuration [max-run-duration]
   7.605 [id=90]	INFO	c.g.j.p.c.ComputeEngineComputerLauncher#launch: Launch will wait 300000 for operation operation-1736325861584-62b2dde31aed6-64bb755c-3c990531 to complete...
   7.623 [id=93]	INFO	c.g.j.p.c.ComputeEngineCloud#lambda$getPlannedNodeFuture$0: Waiting 300000ms for node max-run-duration-0ypabi to connect
  22.516 [id=90]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Launching instance: max-run-duration-0ypabi
  22.518 [id=90]	INFO	c.g.j.p.c.ComputeEngineCloud#log: bootstrap
  22.519 [id=90]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Getting keypair...
  22.520 [id=90]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Using autogenerated ssh keypair
  22.520 [id=90]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Authenticating as jenkins
  24.000 [id=90]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Connecting to 34.138.132.147 on port 22, with timeout 10000.
  26.385 [id=90]	WARNING	c.g.j.p.c.ComputeEngineCloud#log: An error occured: There was a problem while connecting to 34.138.132.147:22
  32.896 [id=90]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Connecting to 34.138.132.147 on port 22, with timeout 10000.
  33.145 [id=90]	WARNING	c.g.j.p.c.ComputeEngineCloud#log: An error occured: There was a problem while connecting to 34.138.132.147:22
  39.661 [id=90]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Connecting to 34.138.132.147 on port 22, with timeout 10000.
  42.625 [id=90]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Connected via SSH.
  43.712 [id=90]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Verifying: /usr/bin/java -fullversion
  45.610 [id=90]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Copying agent.jar to: /tmp
  48.864 [id=90]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Launching Jenkins agent via plugin SSH: /usr/bin/java -jar /tmp/agent.jar
  76.560 [id=90]	INFO	c.g.j.p.c.ComputeEngineComputer#onConnected: Instance max-run-duration-0ypabi is preemptive, setting up preemption listener
  76.581 [id=93]	INFO	c.g.j.p.c.ComputeEngineCloud#lambda$getPlannedNodeFuture$0: 68958ms elapsed waiting for node max-run-duration-0ypabi to connect
  78.168 [f #1] Legacy code started this job.  No cause information is available
  78.168 [f #1] Running as SYSTEM
  78.224 [f #1] Building remotely on max-run-duration-0ypabi (integration) in workspace /tmp/workspace/f
 145.730 [f #1] [f] $ /bin/sh -xe /tmp/jenkins4871968057702516940.sh
 149.589 [f #1] + echo hello world
 149.590 [f #1] hello world
 162.204 [f #1] Finished: SUCCESS
 221.253 [id=122]	INFO	h.r.SynchronousCommandTransport$ReaderThread#run: I/O error in channel max-run-duration-0ypabi
java.io.EOFException
    at java.base/java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2926)
    at java.base/java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:3421)
    at java.base/java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:959)
    at java.base/java.io.ObjectInputStream.<init>(ObjectInputStream.java:397)
    at hudson.remoting.ObjectInputStreamEx.<init>(ObjectInputStreamEx.java:50)
    at hudson.remoting.Command.readFrom(Command.java:142)
    at hudson.remoting.Command.readFrom(Command.java:128)
    at hudson.remoting.AbstractSynchronousByteArrayCommandTransport.read(AbstractSynchronousByteArrayCommandTransport.java:35)
    at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:61)
Caused: java.io.IOException: Unexpected termination of the channel
    at hudson.remoting.SynchronousCommandTransport$ReaderThread.run(SynchronousCommandTransport.java:75)
 320.082 [id=148]	INFO	c.g.j.p.c.ComputeEngineComputerLauncher#launch: Launch will wait 300000 for operation operation-1736325861584-62b2dde31aed6-64bb755c-3c990531 to complete...
 329.061 [p #1] Started
 329.281 [p #1] [Pipeline] Start of Pipeline
 329.334 [p #1] [Pipeline] node
 332.656 [id=67]	INFO	c.g.j.p.c.ComputeEngineCloud#provision: Provisioning node from configs [com.google.jenkins.plugins.computeengine.InstanceConfiguration@545a028e] for excess workload of 1 units of label 'integration'
 333.420 [id=67]	INFO	c.g.j.p.c.ComputeEngineCloud#availableNodeCapacity: Found capacity for 10 nodes in cloud integration
 333.421 [id=67]	INFO	c.g.j.p.c.InstanceConfiguration#instance: User selected to use an autogenerated ssh key pair
 335.869 [id=67]	INFO	c.g.j.p.c.InstanceConfiguration#provision: Sent insert request for instance configuration [max-run-duration]
 335.872 [id=148]	INFO	c.g.j.p.c.ComputeEngineComputerLauncher#launch: Launch will wait 300000 for operation operation-1736326189883-62b2df1c32122-8ab9a70e-c31ad270 to complete...
 335.885 [id=152]	INFO	c.g.j.p.c.ComputeEngineCloud#lambda$getPlannedNodeFuture$0: Waiting 300000ms for node max-run-duration-s7l5ug to connect
 335.885 [id=67]	INFO	h.s.NodeProvisioner$StandardStrategyImpl#apply: Started provisioning max-run-duration-s7l5ug from gce-integration with 1 executors. Remaining excess workload: 0
 344.358 [p #1] Still waiting to schedule task
 344.359 [p #1] ‘max-run-duration-s7l5ug’ is offline
 345.302 [id=148]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Launching instance: max-run-duration-s7l5ug
 345.303 [id=148]	INFO	c.g.j.p.c.ComputeEngineCloud#log: bootstrap
 345.303 [id=148]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Getting keypair...
 345.304 [id=148]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Using autogenerated ssh keypair
 345.304 [id=148]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Authenticating as jenkins
 346.746 [id=148]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Connecting to 104.196.141.235 on port 22, with timeout 10000.
 356.746 [id=148]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Failed to connect via ssh: The connect() operation on the socket timed out.
 356.748 [id=148]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Waiting for SSH to come up. Sleeping 5.
 363.273 [id=148]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Connecting to 104.196.141.235 on port 22, with timeout 10000.
 366.264 [id=148]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Connected via SSH.
 367.373 [id=148]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Verifying: /usr/bin/java -fullversion
 369.282 [id=148]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Copying agent.jar to: /tmp
 372.835 [id=148]	INFO	c.g.j.p.c.ComputeEngineCloud#log: Launching Jenkins agent via plugin SSH: /usr/bin/java -jar /tmp/agent.jar
 401.209 [id=148]	INFO	c.g.j.p.c.ComputeEngineComputer#onConnected: Instance max-run-duration-s7l5ug is preemptive, setting up preemption listener
 401.221 [id=152]	INFO	c.g.j.p.c.ComputeEngineCloud#lambda$getPlannedNodeFuture$0: 65336ms elapsed waiting for node max-run-duration-s7l5ug to connect
 405.603 [p #1] Running on max-run-duration-s7l5ug in /tmp/workspace/p
 405.658 [p #1] [Pipeline] {
 405.658 [p #1] [Pipeline] sh
 495.486 [p #1] + date
 495.487 [p #1] Wed Jan  8 08:52:19 UTC 2025
 496.757 [p #1] [Pipeline] }
 496.815 [p #1] [Pipeline] // node
 496.815 [p #1] [Pipeline] End of Pipeline
 496.853 [p #1] Finished: SUCCESS
 498.368 [id=21]	INFO	c.g.j.p.c.integration.ITUtil#teardownResources: teardown
 499.103 [id=21]	INFO	c.g.j.p.c.integration.ITUtil#deleteIntegrationInstances: Cleaning up old instances; found 1 instances to delete, it may take a while for this deletion
 499.103 [id=21]	INFO	c.g.j.p.c.integration.ITUtil#safeDelete: deleting instance: max-run-duration-s7l5ug
 500.960 [id=21]	INFO	hudson.lifecycle.Lifecycle#onStatusUpdate: Stopping Jenkins
 500.993 [id=21]	INFO	hudson.lifecycle.Lifecycle#onStatusUpdate: Jenkins stopped
 501.033 [id=21]	INFO	o.j.h.t.TemporaryDirectoryAllocator#dispose: deleting /Users/gbhat/CBProjects/google-compute-engine-plugin/target/tmp/j h1716315002771573716
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 501.5 s -- in com.google.jenkins.plugins.computeengine.integration.SpotVmProvisioningWithMaxRunDurationCasCIT
[INFO]
[INFO] Results:
[INFO]
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  08:26 min
[INFO] Finished at: 2025-01-08T14:22:36+05:30
[INFO] ------------------------------------------------------------------------
➜  google-compute-engine-plugin git:(add-max-run-duration-to-vm-provisioning) ✗

Submitter checklist

  • Make sure you are opening from a topic/feature/bugfix branch (right side) and not your main branch!
  • Ensure that the pull request title represents the desired changelog entry
  • Please describe what you did
  • Link to relevant issues in GitHub or Jira
  • Link to relevant pull requests, esp. upstream and downstream changes
  • Ensure you have provided tests - that demonstrates feature works or fixes the issue

@gbhat618
Copy link
Contributor Author

👋 @jglick , @Vlatombe , @nevingeorgesunny

@gbhat618
Copy link
Contributor Author

gbhat618 commented Dec 12, 2024

recording and screenshots moved to the summary at the top ⬆️

@gbhat618
Copy link
Contributor Author

gbhat618 commented Dec 12, 2024

I will work on the testing as,

  • check and update automated tests (or write new tests)
  • Jcasc based testing
  • what happens to agents in jenkins if the vm got deleted in GCP due to maxRunDuration (maybe jenkins will mark agent as non-available - but will test and update the notes).

Edit: all these points are completed ✔️ (automated tests are written both unittests and integration test). When maxRunDuration deletes the VM in GCP side, the controller also deletes the slave, which is correct no issues for builds ✅ (already covered in the integration test)

@gbhat618 gbhat618 marked this pull request as ready for review December 16, 2024 18:19
@gbhat618
Copy link
Contributor Author

👋 Completed the PR from draft to ready, plz help review @jglick , @Vlatombe , @nevingeorgesunny

@gbhat618 gbhat618 requested a review from rsandell December 18, 2024 14:26
-->
<div>
The maximum duration (in seconds) after which the VM will be automatically deleted by GCP.
See <a href="https://cloud.google.com/compute/docs/instances/limit-vm-runtime">Limit the run time of a VM</a> for more details.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI, links in help files for config forms automatically open in a new tab/window as per some magic in Jenkins core—there is no need to manually right-click and select Open in new tab or similar.

docs/integration-tests.md Outdated Show resolved Hide resolved
docs/integration-tests.md Outdated Show resolved Hide resolved
docs/integration-tests.md Outdated Show resolved Hide resolved
@@ -120,7 +124,7 @@ public class InstanceConfiguration implements Describable<InstanceConfiguration>
private String machineType;
private String numExecutorsStr;
private String startupScript;
private boolean preemptible;
private ProvisioningType provisioningType;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note for reviewers: this class is using Lombok (not a good idea!):

@gbhat618 gbhat618 mentioned this pull request Dec 20, 2024
6 tasks
}

@SuppressWarnings("unused") // jelly
public FormValidation doCheckMaxRunDurationSeconds(@QueryParameter String value) {

Check warning

Code scanning / Jenkins Security Scan

Stapler: Missing POST/RequirePOST annotation Warning

Potential CSRF vulnerability: If DescriptorImpl#doCheckMaxRunDurationSeconds connects to user-specified URLs, modifies state, or is expensive to run, it should be annotated with @POST or @RequirePOST
}

@SuppressWarnings("unused") // jelly
public FormValidation doCheckMaxRunDurationSeconds(@QueryParameter String value) {

Check warning

Code scanning / Jenkins Security Scan

Stapler: Missing permission check Warning

Potential missing permission check in DescriptorImpl#doCheckMaxRunDurationSeconds
}

@SuppressWarnings("unused") // jelly
public FormValidation doCheckMaxRunDurationSeconds(@QueryParameter String value) {

Check warning

Code scanning / Jenkins Security Scan

Stapler: Missing POST/RequirePOST annotation Warning

Potential CSRF vulnerability: If DescriptorImpl#doCheckMaxRunDurationSeconds connects to user-specified URLs, modifies state, or is expensive to run, it should be annotated with @POST or @RequirePOST
}

@SuppressWarnings("unused") // jelly
public FormValidation doCheckMaxRunDurationSeconds(@QueryParameter String value) {

Check warning

Code scanning / Jenkins Security Scan

Stapler: Missing permission check Warning

Potential missing permission check in DescriptorImpl#doCheckMaxRunDurationSeconds
pom.xml Outdated Show resolved Hide resolved
public void setPreemptible(boolean preemptible) {
if (preemptible) {
this.provisioningType = new PreemptibleVm();
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

setPreemptible(false) is noop?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for JCasC compatibility purpose (as it was small effort)
as in #492 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants