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

Jobs created by doCreateItem start with build #0

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Minor Minor
    • core
    • None
    • Platform: All, OS: All

      If you create a job through the web UI, the first build is #1. If you post
      config.xml to /createItem?name=..., the first build is #0.

      Debugger confirms that when Job.onLoad is run, nextBuildNumber==0, despite

      protected transient volatile int nextBuildNumber = 1;

      Some XStream magic I suppose.

          [JENKINS-3361] Jobs created by doCreateItem start with build #0

          Jesse Glick created issue -
          SCM/JIRA link daemon made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]
          Andrew Bayer made changes -
          Status Original: Resolved [ 5 ] New: Closed [ 6 ]
          R. Tyler Croy made changes -
          Workflow Original: JNJira [ 133434 ] New: JNJira + In-Review [ 202159 ]

            Unassigned Unassigned
            jglick Jesse Glick
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: