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

using ClearCase plugin without config spec and load rules field (load them from files)

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Major Major
    • clearcase-plugin
    • None
    • Windows XP SP3, Hudson 1.388, ClearCase plugin 1.3.5

      I'm using ClearCase plugin for my build server. The ConfigSpec for the view is created automatically (via script) and also the view is created automatically. Now i need the possibility that Hudson extracts the config spec from special file (incl. rules etc.), because it's not usable that i always paste the config spec to Hudson configuration manually after it was changed atomatically with script. It should be possible to use the plugin with file names for config spec and load rules. I'm using Base-ClearCase with snapshot views.

          [JENKINS-8305] using ClearCase plugin without config spec and load rules field (load them from files)

          anb0s added a comment -

          I will add one checkbox with file name field:
          [x] get config spec from file
          (if checked config spec field will be hidden and the config spec will be loaded from given file)

          and checkbox for load rules:
          [x] get load rules from config spec

          and if it's usable:
          [x] get branch names from config spec
          [x] get label names from config spec

          anb0s added a comment - I will add one checkbox with file name field: [x] get config spec from file (if checked config spec field will be hidden and the config spec will be loaded from given file) and checkbox for load rules: [x] get load rules from config spec and if it's usable: [x] get branch names from config spec [x] get label names from config spec

          anb0s added a comment - - edited

          -

          anb0s added a comment - - edited -

          anb0s added a comment -

          I implemented and tested some new options for our use case (see JENKINS-8687 and JENKINS-8684).

          User can enable reading cspec from file and this file can be optionaly refreshed (updated) before checkout with given command. The file name is added to env as 'CLEARCASE_CSFILENAME' and ca be used in "refresh command" field. If SCM polling is enabled one of the checks is to execute the refresh command and compare the cspec file with used cspec, if they are different BUILD_NOW is returned -> build is started. Because our script (cc_refresh.cmd) creates cspec file with load rules for snapshot views, new option for reading load rules from cspec was added.

          New options with example configuration:

          [x] get config spec from file
            file name: d:\views\${JOB_NAME}.txt
            [x] refresh config spec file
              refresh command: cc_refresh.cmd -b ${JOB_NAME} -f ${CLEARCASE_CSFILENAME}
          [x] get load rules from config spec
          

          anb0s added a comment - I implemented and tested some new options for our use case (see JENKINS-8687 and JENKINS-8684 ). User can enable reading cspec from file and this file can be optionaly refreshed (updated) before checkout with given command. The file name is added to env as 'CLEARCASE_CSFILENAME' and ca be used in "refresh command" field. If SCM polling is enabled one of the checks is to execute the refresh command and compare the cspec file with used cspec, if they are different BUILD_NOW is returned -> build is started. Because our script (cc_refresh.cmd) creates cspec file with load rules for snapshot views, new option for reading load rules from cspec was added. New options with example configuration: [x] get config spec from file file name: d:\views\${JOB_NAME}.txt [x] refresh config spec file refresh command: cc_refresh.cmd -b ${JOB_NAME} -f ${CLEARCASE_CSFILENAME} [x] get load rules from config spec

          anb0s added a comment -

          It worked now for some weeks in our build machine. Is it useful for other users?

          anb0s added a comment - It worked now for some weeks in our build machine. Is it useful for other users?

          davidmc24 added a comment -

          My use case is both similar and different. The company I work at uses ClearCase UCM, so our config specs are mostly managed by the streams. However, we still need to specify load rules. If there was an easy way to have the Hudson ClearCase plugin use the config spec from a UCM stream with load rules specified in a file (ideally, even a file path relative to the view root, so that as the stream changes, the load rules needed can also change automatically), that would be highly useful.

          davidmc24 added a comment - My use case is both similar and different. The company I work at uses ClearCase UCM, so our config specs are mostly managed by the streams. However, we still need to specify load rules. If there was an easy way to have the Hudson ClearCase plugin use the config spec from a UCM stream with load rules specified in a file (ideally, even a file path relative to the view root, so that as the stream changes, the load rules needed can also change automatically), that would be highly useful.

          anb0s added a comment -

          anb0s added a comment - Integrated patch at https://github.com/anb0s/clearcase-plugin/tree/integrate_1.3.8

          anb0s added a comment -

          fixed in >= 1.3.9

          anb0s added a comment - fixed in >= 1.3.9

            anb0s anb0s
            anb0s anb0s
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: