• Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Minor Minor
    • core
    • 2.428

      In CloudBees CI, we implemented a custom Lifecycle implementation in a plugin.

      The existing implementation of Lifecycle relied on UberClassloader however it was running before any plugin was loaded, so in practice setting a custom lifecycle coming from a plugin through the system property hudson.lifecycle was causing Jenkins startup to fail.

      This is proposing a way for plugins to contribute custom lifecycles that can be activated using the system property hudson.lifecycle.

          [JENKINS-72111] Pluggable Lifecycle

          Vincent Latombe created issue -
          Vincent Latombe made changes -
          Labels New: api
          Vincent Latombe made changes -
          Assignee New: Vincent Latombe [ vlatombe ]
          Vincent Latombe made changes -
          Status Original: Open [ 1 ] New: In Progress [ 3 ]
          Vincent Latombe made changes -
          Remote Link New: This issue links to "PR #8555 (Web Link)" [ 28955 ]
          Vincent Latombe made changes -
          Status Original: In Progress [ 3 ] New: In Review [ 10005 ]
          Jesse Glick made changes -
          Assignee Original: Vincent Latombe [ vlatombe ] New: Jesse Glick [ jglick ]
          Vincent Latombe made changes -
          Description Original: In CloudBees CI, we implemented a custom Lifecycle implementation in a plugin.

          With the way the Lifecycle class is implemented, {{Lifecycle.get()}} could get called even before plugins are initialized, and so it is not safe to pass a plugin-defined lifecycle to the system property {{hudson.lifecycle}}

          This proposes to add a setter method allowing a plugin to update the active lifecycle.
          New: In CloudBees CI, we implemented a custom Lifecycle implementation in a plugin.

          The existing implementation of Lifecycle relied on UberClassloader however it was running before any plugin was loaded, so in practice setting a custom lifecycle coming from a plugin through the system property {{hudson.lifecycle}} was causing Jenkins startup to fail.

          This is proposing a way for plugins to contribute custom lifecycles that can be activated using the system property {{hudson.lifecycle}}.
          Vincent Latombe made changes -
          Remote Link New: This issue links to "PR #8589 (Web Link)" [ 28969 ]
          Vincent Latombe made changes -
          Remote Link Original: This issue links to "PR #8555 (Web Link)" [ 28955 ]
          Jesse Glick made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: In Review [ 10005 ] New: Fixed but Unreleased [ 10203 ]

            jglick Jesse Glick
            vlatombe Vincent Latombe
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: