Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-27601

instance caps incorrectly calculated

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • ec2-plugin
    • None
    • ec2-plugin 1.26
      jenkins 1.605

      Instance counts towards the cap feature are incorrectly counted when you use the same AMI for multiple jenkins slave types it with differing ec2 instance types. The count is a sum of all the instances provisioned by the plugin rather than the number provisioned per discrete slave configuration.

      https://github.com/jenkinsci/ec2-plugin/blob/master/src/main/java/hudson/plugins/ec2/EC2Cloud.java#L241

      If the ami id and the tag jenkins_slave_type match, it is counted toward the cap.

      Scenario:

      slave description: small slave
      ami: ami-12345
      instance type: t1.small
      cap: 5

      slave description: big slave
      ami: ami-12345
      instance type: c3.xlarge
      cap: 2

      If there are five "small slaves" running it won't provision any "big slaves", reports the following:

      AMI Instance cap of 2 reached for ami ami-12345, not provisioning.

            francisu Francis Upton
            trbaker Trevor Baker
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: