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

Timestamp display mode not persisted when Jenkins running from top-level URL

    XMLWordPrintable

Details

    Description

      I like the elapsed mode (timestamps counted from the beginning of the job) very much, but currently I have to select it every time I open a console log for a build.

      I'd prefer to select it once and forget that other modes even exist.

      Suggestion: add an option to the "Configure System" screen for setting the default mode.

      Attachments

        Issue Links

          Activity

            mgedmin Marius Gedminas created issue -
            elmi82 Timo Müller added a comment -

            Setting the mode is still persisted but only on a build level. The reason being this change JENKINS-29899. The cookie's path contains the build number and does not affect the display of any other builds of the job.

            It would be nice to switch the mode of all console logs of a Job in general. Setting the path of the cookie to the Job URL would do the trick. An option in the Job configuration to set the default display would of course also be fine.

            elmi82 Timo Müller added a comment - Setting the mode is still persisted but only on a build level. The reason being this change JENKINS-29899 . The cookie's path contains the build number and does not affect the display of any other builds of the job. It would be nice to switch the mode of all console logs of a Job in general. Setting the path of the cookie to the Job URL would do the trick. An option in the Job configuration to set the default display would of course also be fine.
            stevengbrown Steven G Brown made changes -
            Field Original Value New Value
            Summary Allow me to choose default timestamp mode Timestamp display mode not persisted when Jenkins running from top-level URL
            stevengbrown Steven G Brown added a comment - - edited

            The intention of JENKINS-29899 was to store the cookies at the Jenkins instance level. It sets the cookie path to rootURL and this works as expected for URLs like http://example.com/jenkins.

            However, when running from the top-level URL (e.g. http://example.com), the rootURL is empty, so the browser stores the cookies on the current path.

            stevengbrown Steven G Brown added a comment - - edited The intention of JENKINS-29899 was to store the cookies at the Jenkins instance level. It sets the cookie path to rootURL and this works as expected for URLs like http://example.com/jenkins . However, when running from the top-level URL (e.g. http://example.com ), the rootURL is empty, so the browser stores the cookies on the current path.
            stevengbrown Steven G Brown made changes -
            Link This issue is related to JENKINS-29899 [ JENKINS-29899 ]

            Code changed in jenkins
            User: Steven Brown
            Path:
            src/main/resources/hudson/plugins/timestamper/annotator/TimestampAnnotatorFactory/script.js
            http://jenkins-ci.org/commit/timestamper-plugin/26f6fdb2d47f88e1fe8afd454407fc5283eaeb6b
            Log:
            [FIXED JENKINS-32074] When rootURL is empty, store cookies at '/'

            When Jenkins is running from the top-level URL, the rootURL variable is an empty
            string. In this case, store the cookies at '/' instead of rootURL.

            Prior to this change, the cookies were created with an empty path, and the
            browser defaults to storing them at the build URL. These cookies will now be
            deleted because they would override the cookies stored at the Jenkins URL.

            Bug introduced by JENKINS-29899.

            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Steven Brown Path: src/main/resources/hudson/plugins/timestamper/annotator/TimestampAnnotatorFactory/script.js http://jenkins-ci.org/commit/timestamper-plugin/26f6fdb2d47f88e1fe8afd454407fc5283eaeb6b Log: [FIXED JENKINS-32074] When rootURL is empty, store cookies at '/' When Jenkins is running from the top-level URL, the rootURL variable is an empty string. In this case, store the cookies at '/' instead of rootURL. Prior to this change, the cookies were created with an empty path, and the browser defaults to storing them at the build URL. These cookies will now be deleted because they would override the cookies stored at the Jenkins URL. Bug introduced by JENKINS-29899 .

            Released with Timestamper 1.7.3. Thanks for your investigative work, Timo.

            stevengbrown Steven G Brown added a comment - Released with Timestamper 1.7.3. Thanks for your investigative work, Timo.
            stevengbrown Steven G Brown made changes -
            Resolution Fixed [ 1 ]
            Status Open [ 1 ] Resolved [ 5 ]
            rtyler R. Tyler Croy made changes -
            Workflow JNJira [ 167555 ] JNJira + In-Review [ 198229 ]

            People

              stevengbrown Steven G Brown
              mgedmin Marius Gedminas
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: