-
Notifications
You must be signed in to change notification settings - Fork 82
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
Fix cloud tracking #383
Fix cloud tracking #383
Conversation
… tracking of cloud instance [refactor] Added instanceId to FleetNode for clarity, added getDescriptor to return sub type [refactor] Dont provision if Jenkins is quieting down and terminating Fix jenkinsci#360 Fix jenkinsci#322
@@ -4,16 +4,12 @@ | |||
xmlns:t="/lib/hudson" xmlns:f="/lib/form" | |||
xmlns:c="/lib/credentials"> | |||
|
|||
<f:description>A unique name for this EC2 Fleet cloud</f:description> | |||
<f:description>Warning: Cloud name is used to track agents belonging to this cloud. Please do not modify an existing cloud's name. See <a href="https://github.com/jenkinsci/ec2-fleet-plugin/issues/382">this issue</a> for details</f:description> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this warning the only barrier in place from changing the cloud name? What would happen to existing agents if a cloud name is changed?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Unfortunately yes. I meant to create another task to implement disallowing name change. This PR is already handling a lot, so didn't want to overload it.
@@ -338,13 +338,14 @@ public void should_continue_update_after_termination() throws IOException { | |||
j.jenkins.getLabelAtom("momo").nodeProvisioner.suggestReviewNow(); | |||
System.out.println("tasks submitted"); | |||
|
|||
// wait full execution | |||
// wait ful l execution |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: spacing on the comment
Context
Jenkins Cloud represents user configuration and is bound to the corresponding user input data. i.e. a user-initiated change to the cloud configuration recreates that cloud's instance.
The plugin currently passes the cloud object around to Ec2FleetNode and Ec2FleetNodeComputer in an effort to link them to the cloud they belong to. This becomes problematic when those cloud instances are re-created. The plugin's re-assignment logic has been buggy requiring tracking of
oldId
etc.This PR removes the usage of
oldId
and cloud re-assignments and replaces cloud object tracking with tracking by name making cloud name a special configuration. Hence #382.Related issues:
Changes
Supporting changes:
Testing done
maxTotalUses
Now:
(Logs only used for development)
Before: