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

Providing nodes by "Image name" always works as by "Image ID"

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Won't Fix
    • jclouds-plugin
    • None
    • Jenkins 1.616
      JClouds 2.8

    Description

      Prerequisite:

      • We have image "abc"
      • We have configured Jenkins with JCloud (OpenStack) to allocate new nodes, in node template we specified "Image Name Regexp = abc"

      Steps to reproduce:

      • Allocate new environment (passed step)
      • In cloud delete image "abc" and create a new image with the same name (we have image with new ImageID)
      • Try to allocate new node by Jenkins

      Result:
      Exception: blablabla
      Jenkins tries to create a new node by missingg ImageId

      Expected result:
      Jenkins will refind new ImageID by Image Name and create a new node.

      Attachments

        Activity

          felfert Fritz Elfert added a comment -

          Hi,
          Actually, this is a caching bug in jclouds.
          I just issued https://github.com/jenkinsci/jclouds-plugin/pull/104 which circumvents jcloud's image cache.

          Cheers
          -Fritz

          felfert Fritz Elfert added a comment - Hi, Actually, this is a caching bug in jclouds. I just issued https://github.com/jenkinsci/jclouds-plugin/pull/104 which circumvents jcloud's image cache. Cheers -Fritz
          felfert Fritz Elfert added a comment -

          @ nikolay_borisenko

          Can you please replace "Exception: blablabla" by a real stacktrace?
          This would help me do create a workaround in the plugin, because it turms out that circumventing the cache isn't a viable option either.

          Thanks
          -Fritz

          felfert Fritz Elfert added a comment - @ nikolay_borisenko Can you please replace "Exception: blablabla" by a real stacktrace? This would help me do create a workaround in the plugin, because it turms out that circumventing the cache isn't a viable option either. Thanks -Fritz
          danielbeck Daniel Beck added a comment -

          felfert Want me to merge jclouds-jenkins into jclouds-plugin and make you component lead? Looks like you're the maintainer after all.

          danielbeck Daniel Beck added a comment - felfert Want me to merge jclouds-jenkins into jclouds-plugin and make you component lead? Looks like you're the maintainer after all.

          Code changed in jenkins
          User: Fritz Elfert
          Path:
          jclouds-plugin/src/main/java/jenkins/plugins/jclouds/compute/JCloudsCloud.java
          jclouds-plugin/src/main/java/jenkins/plugins/jclouds/compute/JCloudsSlaveTemplate.java
          http://jenkins-ci.org/commit/jclouds-plugin/d636f0910302f8ad65da5539bc7500c058d02287
          Log:
          Fixes JENKINS-28815

          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Fritz Elfert Path: jclouds-plugin/src/main/java/jenkins/plugins/jclouds/compute/JCloudsCloud.java jclouds-plugin/src/main/java/jenkins/plugins/jclouds/compute/JCloudsSlaveTemplate.java http://jenkins-ci.org/commit/jclouds-plugin/d636f0910302f8ad65da5539bc7500c058d02287 Log: Fixes JENKINS-28815

          Code changed in jenkins
          User: Fritz Elfert
          Path:
          jclouds-plugin/src/main/java/jenkins/plugins/jclouds/compute/JCloudsSlaveTemplate.java
          http://jenkins-ci.org/commit/jclouds-plugin/247b1415cce9e3efdac2cce1764ef8157aec6242
          Log:
          Fix JENKINS-28815, 2nd attempt

          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Fritz Elfert Path: jclouds-plugin/src/main/java/jenkins/plugins/jclouds/compute/JCloudsSlaveTemplate.java http://jenkins-ci.org/commit/jclouds-plugin/247b1415cce9e3efdac2cce1764ef8157aec6242 Log: Fix JENKINS-28815 , 2nd attempt

          Code changed in jenkins
          User: Fritz Elfert
          Path:
          jclouds-plugin/src/main/java/jenkins/plugins/jclouds/compute/JCloudsCloud.java
          jclouds-plugin/src/main/java/jenkins/plugins/jclouds/compute/JCloudsSlaveTemplate.java
          http://jenkins-ci.org/commit/jclouds-plugin/c36d74077e0c298e9f0356bc114da4f4060eb086
          Log:
          Merge pull request #104 from OpenDataSpace/JENKINS-28815

          JENKINS-28815 Providing nodes by "Image name" always works as by "Image ID"

          Compare: https://github.com/jenkinsci/jclouds-plugin/compare/686a366ff7fd...c36d74077e0c

          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Fritz Elfert Path: jclouds-plugin/src/main/java/jenkins/plugins/jclouds/compute/JCloudsCloud.java jclouds-plugin/src/main/java/jenkins/plugins/jclouds/compute/JCloudsSlaveTemplate.java http://jenkins-ci.org/commit/jclouds-plugin/c36d74077e0c298e9f0356bc114da4f4060eb086 Log: Merge pull request #104 from OpenDataSpace/ JENKINS-28815 JENKINS-28815 Providing nodes by "Image name" always works as by "Image ID" Compare: https://github.com/jenkinsci/jclouds-plugin/compare/686a366ff7fd...c36d74077e0c
          felfert Fritz Elfert added a comment -

          Changed in git (to some degree).
          This is actually caused by caching performed by the underlying jclouds lib. I tried circumventing it as best as possible and it as improved slightly, however it may still need a few minutes or so to actually see changes in the image storage. I talked with jclouds developers about that, and they explained that there is nothing that can be done, because in a big environment (like Amazon for example) there are thousands of images that need to be filtered and it would take ages to iterate over tem. Therfore they do the caching.

          felfert Fritz Elfert added a comment - Changed in git (to some degree). This is actually caused by caching performed by the underlying jclouds lib. I tried circumventing it as best as possible and it as improved slightly, however it may still need a few minutes or so to actually see changes in the image storage. I talked with jclouds developers about that, and they explained that there is nothing that can be done, because in a big environment (like Amazon for example) there are thousands of images that need to be filtered and it would take ages to iterate over tem. Therfore they do the caching.

          People

            felfert Fritz Elfert
            nikolay_borisenko Nikolay Borisenko
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: